08-20-2006, 06:54 AM
| THREAD STARTER
#1 (permalink)
|
| Senior Member Join Date: Aug 2005 Location: East Yorkshire, England
Posts: 2,689
| A handy bit of code Lets say, you let each user choose a theme, and the url of the css for that theme was stored in a database. If you are using dreamweaver and want your pages to look nice (ie: WITH a style sheet) while you edit them, use this code. How this works is:
1) Dreamweaver sees the HTML and renders it.
2) The PHP parser sees the if statement if(1 == 2), 1 does not equal 2, so the html is not rendered.
3) Because 1 does not equal 2, the alternate style sheet is used instead.
Basicly, it uses your stylesheet when your editing it in dreamweaver, but another stylesheet when online. |
| |