官术网_书友最值得收藏!

Wireframes

When working on commercial projects, it is common for web page designs to be provided to web developers in the form of a wireframe. A wireframe is a low-fidelity design that provides enough information about a page for the developer to start coding. Usually, they will not include much visual design information and are focused on the main structure of a page. The following figure is an example of a wireframe for a new home page:

Figure 2.12: Example of a wireframe

Activity 2.01: Video Store Home Page

Suppose you are a frontend developer working for a tech start-up. You have been asked to build a home page for the online video store. You have been given the following wireframe from the UX designer:

Figure 2.13: Wireframe as per the UX designer's expectation

Using your newly acquired HTML5 knowledge, you can start to convert the wireframe into working HTML code. At this stage, you should just be concerned with writing the structural HTML tags and shouldn't worry about content right now.

The aim will be to achieve a web page similar the following output screenshot:

Figure 2.14: Expected output of video store home page

The steps are as follows:

  1. Create a file named home.html in VSCode.
  2. Use the following code as a page skeleton. Again, do not worry about not understanding the styling part of the code:

    <!DOCTYPE html>

    <html>

        <head>

            <title>Video store home page</title>

            <style>

              header,

              nav,

              section,

              footer {

                background: #659494;

                border-radius: 5px;

                color: white;

                font-family: arial, san-serif;

                font-size: 30px;

                text-align: center;

                padding: 30px;

                margin-bottom: 20px;

              }

              header:before,

              nav:before,

              section:before,

              footer:before {

                content: '<';

              }

              header:after,

              nav:after,

              section:after,

              footer:after {

                content: '>';

              }

            </style>

        </head>

        <body>

    <!-- your code will go here -->

        </body>

    </html>

  3. Start adding the HTML5 structural elements inside the body tag one by one, the same as we did in Exercise 2.01, Marking up the Page.
  4. As with Exercise 2.01, Marking up the Page, we will just add the tag name for content such as header and footer.

If you now right-click on the filename in VSCode on the left-hand side of the screen and select open in default browser, you will see the web page in your browser.

Hopefully, you are now getting a feel for the process of putting basic web pages together. We will build on this knowledge in the coming exercises.

Note

The solution to this activity can be found on page 580.

We are now ready to start making our web pages more realistic by learning some CSS page layout techniques.

主站蜘蛛池模板: 陇南市| 昆山市| 西城区| 蒲城县| 阳东县| 潜山县| 海宁市| 台南县| 蓝山县| 碌曲县| 凤庆县| 阳朔县| 东丰县| 白银市| 黑水县| 丹阳市| 鄂托克旗| 修文县| 奉贤区| 金阳县| 论坛| 上高县| 筠连县| 宁夏| 辽阳县| 鲁甸县| 安多县| 吕梁市| 三都| 巨鹿县| 富裕县| 东平县| 汨罗市| 天门市| 浠水县| 平邑县| 信丰县| 新蔡县| 通江县| 白沙| 商洛市|