Basic PHP Templatizing Assignment

From Knowledge Kitchen
Jump to navigation Jump to search


Overview

Convert this design comp into code:

Php basic assignment design comp.png

Requirements

Use PHP to create templates for the header, footer, and products.

  • create an external file for the header
  • create an external file for the footer
  • create an external file for the template of a single product
  • use arrays to store all product data
  • loop through the arrays to generate the HTML code for each product

Suggestions

  • Create the page in HTML & CSS first, before doing any PHP.
  • While developing, use the design comp as the background image for your container.
  • Once the page looks perfect, create the templates in PHP

HTML hints

Download wireframes showing HTML suggestions

PHP hints

See storing data in arrays for hints on how to store the product data on this page into one- or two-dimensional arrays. Two-dimensional arrays are preferable and considered more elegant for tabular data like this.


What links here