Please register with your real name and do not post any SPAM! Violations: "Hk.", "Getagrip", "therain", "learnandwatch" and "lolox" => deleted
0 Members and 1 Guest are viewing this topic.
<?php if (php == $_GET[showsource]) { show_source($_SERVER[SCRIPT_FILENAME]); exit; } elseif (html == $_GET[showsource]) { show_source(dirname(__FILE__) . /tmpl/basic.htm); exit; } require_once vlib/vlibTemplate.php; $tmpl = new vlibTemplate(tmpl/basic.htm); $tmpl->setvar(title_text, TITLE: This is the vLIB basic example ...); $tmpl->setvar(body_text, BODY: This is the message set using setvar()); $tmpl->pparse();?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"><html><head> <title>{tmpl_var name=title_text}</title> <meta http-equiv="content-type" content="text/html; charset=iso-8859-1" /></head><body><p>{tmpl_var name=body_text}</p><p><a href="basic.php?showsource=php">show PHP code</a> |<a href="basic.php?showsource=html">show template (HTML code)</a></p></body></html>