Thursday 15 April 2010

html5 - What ways are there make HTML modular? -


HTML often repeats and is an independent structure that is modular at theoretical level, such as many portfolio items:

  & lt; Div class = "protfolio-item" & gt; & Lt; Div class = "image" & gt; & Lt; A ... & gt; & Lt; Img / & gt; & Lt; / A & gt; ... & lt; / Div & gt; & Lt; Div class = "portfolio-content" & gt; & Lt; H2 & gt; ... & lt; / H2 & gt; & Lt; P & gt; ... & lt; / P & gt; & Lt; / Div & gt; & Lt; / Div & gt;   

Even writing them is stupid. Now I want to make a change, like an icon is left on every picture. What are the ways to get more modular codes, which are easy to change? Are there any non-PHP "basic" ways to do this?

Non-PHP native? First of all I can imagine that is included in server side - not very powerful but you can make your document modular and split it into pieces. The main disadvantage is the lack of loop.

No comments:

Post a Comment