-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<!DOCTYPE html>
<!-- This file is an example template for wfpl/template.php. It contains two
special things: sub-templates and template tags. -->
-<html xmlns="http://www.w3.org/1999/xhtml">
+<html>
<head>
<title></title>
</head>
sub-template. It marks a section of template which the php can decide how
many times to display (including none.) -->
- <!--~login start~-->
+ <!--~login {~-->
<h3>Please Log In Below</h3>
<form method="get" action="tem_test.php">
putting it in a text file or e-mail then leave the encoding off and
just put ~user~. -->
- <td><input type="text" name="user" value="~user.attr~" /></td>
+ <td><input type="text" name="user" value="~user attr~"></td>
</tr>
<tr>
<!-- there's another template tag named pass -->
- <td><input type="password" name="pass" value="~pass.attr~" /></td>
+ <td><input type="password" name="pass" value="~pass attr~"></td>
</tr>
<tr>
- <td colspan="2"><input type="submit" value="Log In" /></td>
+ <td colspan="2"><input type="submit" value="Log In"></td>
</tr>
</table>
</form>
<!-- and here's the mark for the end of the login sub-template. -->
- <!--~end~-->
+ <!--~}~-->
<!-- Now for a more complex example of sub-templates. This whole table is in
a sub-template so php can decide to display the whole bit or not. First the
marker for the begining of the sub-template -->
- <!--~foobar_table start~-->
+ <!--~foobar_table {~-->
<h3>All your foobar:</h3>
<table summary="">
in this table, so we make a template with just one row, and mark that row
as a sub-template named foobar_row -->
- <!--~foobar_row start~-->
+ <!--~foobar_row {~-->
<tr>
<!-- sorry that the following tag looks a bit like a filename. It isn't.
It's simply asking PHP for a value called "foo" encoded as html -->
- <td>~foo.html~</td>
+ <td>~foo html~</td>
- <td><input value="~bar.attr~" /></td>
+ <td><input value="~bar attr~"></td>
</tr>
<!-- Here's the end of foobar_row -->
- <!--~end~-->
+ <!--~}~-->
<tr>
<td></td>
- <td><input type="submit" /></td>
+ <td><input type="submit"></td>
</tr>
</table>
<!-- and the end of foobar_table -->
- <!--~end~-->
+ <!--~}~-->
</body>
</html>