return $str;
}
-# Encode for output in html. Convert newlines to <br />
+# Encode for output in html. Convert newlines to <br>
#
# Example: <p>~foo htmlbr~</p>
function enc_htmlbr($str) {
$str = enc_html($str);
- $str = str_replace("\n", "<br />\n", $str);
+ $str = str_replace("\n", "<br>\n", $str);
return $str;
}
# Encode for output in html. Preserves newlines and indentation by converting
-# newlines to <br /> and spaces at the begining of lines to
+# newlines to <br> and spaces at the begining of lines to
#
# Example: <p>~foo htmlbrtab~</p>
function enc_htmlbrtab($str) {
return $str;
}
-# Encode for output in html. Spaces converted to and \n to <br />
+# Encode for output in html. Spaces converted to and \n to <br>
#
# Example: <option value="12">~foo htmlbrnbsp~</option>
function enc_htmlbrnbsp($str) {
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<!DOCTYPE html>
-<html xmlns="http://www.w3.org/1999/xhtml">
+<html>
<head>
<title>404 File Not Found</title>
</head>
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<!DOCTYPE html>
-<html xmlns="http://www.w3.org/1999/xhtml">
+<html>
<head>
<title></title>
- <link rel="stylesheet" href="calendar.css" type="text/css" />
+ <link rel="stylesheet" href="calendar.css" type="text/css">
</head>
<body>
# <!--~}~-->
# <p style="font-size: 120%; padding: 5px; margin: 0px">~data html~</p>
# <!--~ sep {~-->
-# <hr />
+# <hr>
# <!--~}~-->
# <!--~ last {~-->
# </div>
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<!DOCTYPE html>
-<html xmlns="http://www.w3.org/1999/xhtml">
+<html>
<head>
<title>Meta Form</title>
</head>
<form action="~metaform_name~" method="get">
<p>The form name should not contain any capitals or symbols (besides underscore)</p>
- <p>File name: <input type="text" name="file_name" value="~file_name attr~" />.html</p>
+ <p>File name: <input type="text" name="file_name" value="~file_name attr~">.html</p>
- <p>DB table: <input type="text" name="table_name" value="~table_name attr~" /></p>
+ <p>DB table: <input type="text" name="table_name" value="~table_name attr~"></p>
- <p>Printable singular: <input type="text" name="singular" value="~singular attr~" /></p>
+ <p>Printable singular: <input type="text" name="singular" value="~singular attr~"></p>
- <p>Printable plural: <input type="text" name="plural" value="~plural attr~" /></p>
+ <p>Printable plural: <input type="text" name="plural" value="~plural attr~"></p>
<h3>Features</h3>
- <p><input type="checkbox" name="opt_email~opt_email checked~" value="Yes" /> Send form results vie e-mail.</p>
+ <p><input type="checkbox" name="opt_email~opt_email checked~" value="Yes"> Send form results vie e-mail.</p>
- <p><input type="checkbox" name="opt_db~opt_db checked~" value="Yes" /> Save form results to a database.</p>
+ <p><input type="checkbox" name="opt_db~opt_db checked~" value="Yes"> Save form results to a database.</p>
- <p><input type="checkbox" name="opt_listing~opt_listing checked~" value="Yes" /> Provide a "Listing" page.</p>
+ <p><input type="checkbox" name="opt_listing~opt_listing checked~" value="Yes"> Provide a "Listing" page.</p>
- <p><input type="checkbox" name="opt_display~opt_display checked~" value="Yes" /> Provide a "Display" page.</p>
+ <p><input type="checkbox" name="opt_display~opt_display checked~" value="Yes"> Provide a "Display" page.</p>
- <p><input type="checkbox" name="opt_pass~opt_pass checked~" value="Yes" /> Password protect this form.</p>
+ <p><input type="checkbox" name="opt_pass~opt_pass checked~" value="Yes"> Password protect this form.</p>
<p>Below, specify the fields you'd like in your form, one field per line. After each field name, put at least one space, then the field type. The following field types are available: <!--~types {~--><!--~types_sep {~-->, <!--~}~-->~type html~<!--~}~-->.</p>
- <p>Example:<br /><pre>
+ <p>Example:<br><pre>
name textbox
phone phone
comments textarea
<p>Fields:
<textarea rows="10" cols="40" name="fields">~fields html~</textarea></p>
- <p><input type="submit" name="preview" value="Continue" /></p>
+ <p><input type="submit" name="preview" value="Continue"></p>
</form>
</body>
</html>
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<!DOCTYPE html>
-<html xmlns="http://www.w3.org/1999/xhtml">
+<html>
<head>
<title>Meta Form</title>
- <link rel="stylesheet" href="code/wfpl/metaform/style.css" type="text/css" />
+ <link rel="stylesheet" href="code/wfpl/metaform/style.css" type="text/css">
</head>
<body>
<h1 class="first">PREVIEW</h1>
~preview~
</div>
- <p><form action="~file_name~.tgz" method="get">~hiddens~<input type="submit" name="download_tar" value="Download tarball" /></form></p>
+ <p><form action="~file_name~.tgz" method="get">~hiddens~<input type="submit" name="download_tar" value="Download tarball"></form></p>
<form action="~metaform_name~" method="get">
- <p><!--~hiddens {~--><input type="hidden" name="file_name" value="~file_name attr~" /><input type="hidden" name="table_name" value="~table_name attr~" /><input type="hidden" name="singular" value="~singular attr~" /><input type="hidden" name="plural" value="~plural attr~" /><input type="hidden" name="opt_email" value="~opt_email yesno~" /><input type="hidden" name="opt_db" value="~opt_db yesno~" /><input type="hidden" name="opt_listing" value="~opt_listing yesno~" /><input type="hidden" name="opt_display" value="~opt_display yesno~" /><input type="hidden" name="opt_pass" value="~opt_pass yesno~" /><input type="hidden" name="fields" value="~fields attr~" /><!--~}~--><input type="submit" name="edit" value="Back to editing" /></p>
+ <p><!--~hiddens {~--><input type="hidden" name="file_name" value="~file_name attr~"><input type="hidden" name="table_name" value="~table_name attr~"><input type="hidden" name="singular" value="~singular attr~"><input type="hidden" name="plural" value="~plural attr~"><input type="hidden" name="opt_email" value="~opt_email yesno~"><input type="hidden" name="opt_db" value="~opt_db yesno~"><input type="hidden" name="opt_listing" value="~opt_listing yesno~"><input type="hidden" name="opt_display" value="~opt_display yesno~"><input type="hidden" name="opt_pass" value="~opt_pass yesno~"><input type="hidden" name="fields" value="~fields attr~"><!--~}~--><input type="submit" name="edit" value="Back to editing"></p>
- <p><input type="submit" name="view_sql" value="View SQL" /></p>
+ <p><input type="submit" name="view_sql" value="View SQL"></p>
- <p><input type="submit" name="view_php" value="View PHP" /></p>
+ <p><input type="submit" name="view_php" value="View PHP"></p>
- <p><input type="submit" name="view_html" value="View HTML template" /></p>
+ <p><input type="submit" name="view_html" value="View HTML template"></p>
- <p><input type="submit" name="view_email" value="View e-mail" /></p>
+ <p><input type="submit" name="view_email" value="View e-mail"></p>
</form>
</body>
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<!DOCTYPE html>
-<html xmlns="http://www.w3.org/1999/xhtml">
+<html>
<head>
<title><!--~~title show {~~-->~plural cap~<!--~~}~~--></title>
- <link rel="stylesheet" href="style.css" type="text/css" /><!--~html_editor_headers {~--><!--~~extra_headers {~~-->
+ <link rel="stylesheet" href="style.css" type="text/css"><!--~html_editor_headers {~--><!--~~extra_headers {~~-->
<script type="text/javascript" src="code/tiny_mce/tiny_mce.js"></script>
<script language="javascript" type="text/javascript">
//<![CDATA[
<!--~~}~~-->
<p style="font-size: 120%; padding: 5px; margin: 0px">~~data html~~</p>
<!--~~ sep {~~-->
- <hr />
+ <hr>
<!--~~}~~-->
<!--~~ last {~~-->
</div>
<table border="0" cellpadding="3" cellspacing="0" summary="">
<!--~display_row {~--><!--~display_image {~-->
- <tr><td class="caption">~caption html~:</td><td><img src="~~~name~ image_src~~" width="~~~name~ image_width~~" height="~~~name~ image_height~~" alt="" /></td></tr>
+ <tr><td class="caption">~caption html~:</td><td><img src="~~~name~ image_src~~" width="~~~name~ image_width~~" height="~~~name~ image_height~~" alt=""></td></tr>
<!--~}~--><!--~display_yesno {~-->
<tr><td class="caption">~caption html~:</td><td>~~~name~ yesno~~</td></tr>
<!--~}~--><!--~display_date {~-->
<!--~~form {~~--><!--~form {~-->
<h2><!--~opt_db {~--><!--~~new_msg {~~-->Add a new ~singular~<!--~~}~~--><!--~~edit_msg {~~-->Edit ~singular~ "~~~always_field~ html~~"<!--~~}~~--><!--~}~--><!--~opt_db_else {~-->Submit a ~singular~<!--~}~--></h2>
- <form action="~file_name~" method="post~enctype_attr~"><!--~opt_db {~--><!--~~editing {~~--><div style="display: none"><input type="hidden" name="~file_name~_edit_id" value="~~~file_name~_edit_id attr~~" /></div><!--~~}~~--><!--~}~--><!--~uploads {~--><input type="hidden" name="MAX_FILE_SIZE" value="~~upload_max_filesize~~" /><!--~}~-->
+ <form action="~file_name~" method="post~enctype_attr~"><!--~opt_db {~--><!--~~editing {~~--><div style="display: none"><input type="hidden" name="~file_name~_edit_id" value="~~~file_name~_edit_id attr~~"></div><!--~~}~~--><!--~}~--><!--~uploads {~--><input type="hidden" name="MAX_FILE_SIZE" value="~~upload_max_filesize~~"><!--~}~-->
<!--~row {~--><!--~image {~-->
<div class="caption">~caption html~</div>
- <div class="field"><input type="file" name="~name~" /><input type="hidden" name="old_~name~" value="~~~name~ attr~~" /></div><!--~}~--><!--~file {~-->
+ <div class="field"><input type="file" name="~name~"><input type="hidden" name="old_~name~" value="~~~name~ attr~~"></div><!--~}~--><!--~file {~-->
<div class="caption">~caption html~</div>
- <div class="field"><input type="file" name="~name~" /><input type="hidden" name="old_~name~" value="~~~name~ attr~~" /></div><!--~}~--><!--~textbox {~-->
+ <div class="field"><input type="file" name="~name~"><input type="hidden" name="old_~name~" value="~~~name~ attr~~"></div><!--~}~--><!--~textbox {~-->
<div class="caption">~caption html~</div>
- <div class="field"><input type="text" name="~name~" value="~~~name~ attr~~" /></div><!--~}~--><!--~date {~-->
+ <div class="field"><input type="text" name="~name~" value="~~~name~ attr~~"></div><!--~}~--><!--~date {~-->
<div class="caption">~caption html~</div>
- <div class="field"><input type="text" name="~name~" value="~~~name~ mmddyyyy attr~~" /> mm/dd/yyyy</div><!--~}~--><!--~password {~-->
+ <div class="field"><input type="text" name="~name~" value="~~~name~ mmddyyyy attr~~"> mm/dd/yyyy</div><!--~}~--><!--~password {~-->
<div class="caption">~caption html~</div>
- <div class="field"><input type="password" name="~name~" value="" /></div><!--~}~--><!--~textarea {~-->
+ <div class="field"><input type="password" name="~name~" value=""></div><!--~}~--><!--~textarea {~-->
<div class="caption">~caption html~</div>
<div class="field"><textarea rows="9" cols="22" name="~name~">~~~name~ html~~</textarea></div><!--~}~--><!--~html {~-->
<div class="caption">~caption html~</div>
<div class="caption">~caption html~</div>
<div class="field"><select name="~name~"><option value="">Choose One:</option><!--~~~name~ states~~--></select></div><!--~}~--><!--~radio {~-->
<div class="caption">~caption html~</div>
- <div class="field"><input type="radio" name="~name~~~~name~ checked~~" /></div><!--~}~--><!--~checkbox {~-->
- <div class="caption"><input type="checkbox" name="~name~~~~name~ checked~~" /> ~caption html~</div>
+ <div class="field"><input type="radio" name="~name~~~~name~ checked~~"></div><!--~}~--><!--~checkbox {~-->
+ <div class="caption"><input type="checkbox" name="~name~~~~name~ checked~~"> ~caption html~</div>
<div class="field"></div><!--~}~--><!--~submit {~-->
<div class="caption"> </div>
- <div class="field"><input type="submit" name="~name~" value="~caption attr~" /></div><!--~}~-->
+ <div class="field"><input type="submit" name="~name~" value="~caption attr~"></div><!--~}~-->
<!--~}~-->
</form>
<!--~}~--><!--~~}~~--><!--~opt_listing {~-->
<table cellspacing="0" cellpadding="4" border="1" summary="">
<!--~listing_head_col {~--><th>~caption~</th><!--~}~--><th> </th><!--~~rows {~~-->
<tr><!--~listing_row_col {~-->
- <td class="listing"><a href="~file_name~?~file_name~_<!--~opt_display_else {~-->edit_<!--~}~-->id=~~id~~"><!--~listing_value_enc {~-->~~~name~ ~listing_enc~~~<!--~}~--><!--~listing_value_thumb {~--><img src="~~~name~ thumb_src~~" width="~~~name~ thumb_width~~" height="~~~name~ thumb_height~~" alt="" /><!--~}~--></a></td><!--~}~-->
+ <td class="listing"><a href="~file_name~?~file_name~_<!--~opt_display_else {~-->edit_<!--~}~-->id=~~id~~"><!--~listing_value_enc {~-->~~~name~ ~listing_enc~~~<!--~}~--><!--~listing_value_thumb {~--><img src="~~~name~ thumb_src~~" width="~~~name~ thumb_width~~" height="~~~name~ thumb_height~~" alt=""><!--~}~--></a></td><!--~}~-->
<td><a href="~file_name~?~file_name~_delete_id=~~id~~" onclick="return confirm('Permanently delete?')">[delete this ~singular~]</a></td>
</tr><!--~~}~~-->
run_php('error_404');
return;
} else {
- echo '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html><head><title>404</title></head><body><h1>404 File Not Found</h1></body></html>';
+ echo '<!DOCTYPE html><html><head><title>404</title></head><body><h1>404 File Not Found</h1></body></html>';
exit();
}
}
run_php('404');
return;
} else {
- echo '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html><head><title>404</title></head><body><h1>404 File Not Found</h1></body></html>';
+ echo '<!DOCTYPE html><html><head><title>404</title></head><body><h1>404 File Not Found</h1></body></html>';
exit();
}
}
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<!DOCTYPE html>
-<html xmlns="http://www.w3.org/1999/xhtml">
+<html>
<head>
<title>testing code/wfpl/session.php</title>
</head>
-<!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>
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>
It's simply asking PHP for a value called "foo" encoded as html -->
<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>
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<!DOCTYPE html>
-<html xmlns="http://www.w3.org/1999/xhtml">
+<html>
<head>
<title>wfpl unit test results</title>
- <meta name="robots" content="none" />
+ <meta name="robots" content="none">
<style type="text/css">
.row_even, .row_odd {
font: 14px monospace;
# Example:
#
# <form action="foo.php" enctype="multipart/form-data" method="post">
-# <input type="hidden" name="MAX_FILE_SIZE" value="2097152" />
-# <input type="file" name="photo" />
-# <input type="submit" name="save" value="Save" />
+# <input type="hidden" name="MAX_FILE_SIZE" value="2097152">
+# <input type="file" name="photo">
+# <input type="submit" name="save" value="Save">
# </form>
#
# #######
# the client's name appended. Otherwise $path will be used as the filename
# exactly as is, even if extensions differ between the client's name and $path.
#
-# where user uploads "c:\foo\Bar baz.PDF" at <input name="in" type="file" />
+# where user uploads "c:\foo\Bar baz.PDF" at <input name="in" type="file">
# save_uploaded_file('in', 'uploaded_pdfs/'); yeilds:
# "uploaded_pdfs/bar_baz.pdf"
# save_uploaded_file('in', 'uploaded_pdfs/prefix.'); yeilds:
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<!DOCTYPE html>
-<html xmlns="http://www.w3.org/1999/xhtml">
+<html>
<head>
<title></title>
</head>
<!--~main start~-->
<div id="wfpl_progress_form">
<form action="http://~host~:~port~/~filename~" enctype="multipart/form-data" target="wfpl_progress_post_response" method="post">
- <p>Upload a file: <input type="file" name="wfpl_uploader_file" id="wfpl_uploader_file" /></p>
+ <p>Upload a file: <input type="file" name="wfpl_uploader_file" id="wfpl_uploader_file"></p>
- <p><input type="submit" onclick="submitting()" value="Submit" /></p>
+ <p><input type="submit" onclick="submitting()" value="Submit"></p>
</form>
</div>