note 91017 rejected from index by danbrown

From: Date: Thu, 21 May 2009 12:51:15 +0000
Subject: note 91017 rejected from index by danbrown
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-155836@lists.php.net to get a copy of this message
Note Submitter: roland dot hentschel at t-online dot de ---- 1.) scalable.php : =========== <html> <head> <?php $zf = $_REQUEST["zf"]; $css = file_get_contents($_REQUEST["css"]); function scale($treffer) { global $zf; return $treffer[1]*$zf; } $css = preg_replace_callback('#\[:(.*):\]#Uis', 'scale', $css); echo "<style>\n".$css."\n</style>\n"; ?> </head> <body> <h1>Hallo Welt</h1> <h2>wie geht's?</h2> </body> </html> 2.) scalable.tpl : =========== h1 { font-size:[:16:]px; } h2 { font-size:[:12:]px; } 3.) Implementation: ======= http://localhost/.../scalable.php?css=scalable.tpl&zf=2 4.) PROBLEM ======== Would really like to implement this with "include(...)" or even better with "<script src=...?css=...&zf=...></script>" But just can' get it running. Any idea? Thx a lot in advance ( -: roland :- )

« previous php.notes (#155836) next »