PHP Classes

File: v1/example.php

Recommend this page to a friend!
  Classes of Thomas Björk   CSS parser   v1/example.php   Download  
File: v1/example.php
Role: Example script
Content type: text/plain
Description: Moved the old cssparser to the folder v1 and created a folder v2 with a new CSSParser. The new version is not backwards compatible with the old version. But I've decided to release it in the same package as the old one since it is such an improvement over the old code which was based on code made for PHP4 in 2003.
Class: CSS parser
CSS parser class
Author: By
Last change: Update of v1/example.php
Date: 5 days ago
Size: 325 bytes


Class file image Download

$css = new cssparser();
$css->ParseStr("b {font-weight: bold; color: #777777;} b.test{text-decoration: underline;}");
$css->Get("b","color"); // returns #777777
echo $css->Get("b.test","color");// returns #777777
echo $css->Get(".test","color"); // returns an empty string