- From: Olivier Thereaux via cvs-syncmail <cvsmail@w3.org>
- Date: Wed, 12 Sep 2007 06:09:43 +0000
- To: www-validator-cvs@w3.org
Update of /sources/public/validator/share/templates/en_US In directory hutz:/tmp/cvs-serv3228/templates/en_US Modified Files: table.tmpl ucn_output.tmpl valid.tmpl Log Message: Cleanup of the template variables used to determine whether upload or direct input has been used. This complicates the template structure a little, since HTML::Template does not have <TMPL_ELSIF>, but in the long run it is cleaner than using is_upload for direct input AND upload Index: ucn_output.tmpl =================================================================== RCS file: /sources/public/validator/share/templates/en_US/ucn_output.tmpl,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- ucn_output.tmpl 9 Jul 2007 04:56:27 -0000 1.8 +++ ucn_output.tmpl 12 Sep 2007 06:09:41 -0000 1.9 @@ -60,12 +60,17 @@ </TMPL_IF> </longmessage> <longmessage> - <TMPL_IF NAME="is_upload"> - The uploaded document "<TMPL_VAR NAME="file_uri" ESCAPE="HTML">" - <TMPL_ELSE> - The document located at - <a href="<TMPL_VAR NAME="file_uri" ESCAPE="HTML">"><TMPL_VAR NAME="file_uri" ESCAPE="HTML"></a> - </TMPL_IF> + <TMPL_IF NAME="is_upload"> + The uploaded document "<TMPL_VAR NAME="file_uri" ESCAPE="HTML">" + <TMPL_ELSE> + <TMPL_IF NAME="is_direct_input"> + The uploaded document + <TMPL_ELSE> + The document located at + <<a href="<TMPL_VAR NAME="file_uri" ESCAPE="HTML">"><TMPL_VAR NAME="file_uri" ESCAPE="HTML"></a>> + </TMPL_IF> + </TMPL_IF> + <TMPL_IF NAME="is_tentative"> was checked and found to be <em>tentatively</em> valid <TMPL_VAR NAME="file_version" ESCAPE="HTML">. This means that with the use of some fallback or override mechanism, Index: valid.tmpl =================================================================== RCS file: /sources/public/validator/share/templates/en_US/valid.tmpl,v retrieving revision 1.25 retrieving revision 1.26 diff -u -d -r1.25 -r1.26 --- valid.tmpl 5 Jul 2007 07:10:02 -0000 1.25 +++ valid.tmpl 12 Sep 2007 06:09:41 -0000 1.26 @@ -22,8 +22,12 @@ <TMPL_IF NAME="is_upload"> The uploaded document "<TMPL_VAR NAME="file_uri" ESCAPE="HTML">" <TMPL_ELSE> + <TMPL_IF NAME="is_direct_input"> + The uploaded document + <TMPL_ELSE> The document located at <<a href="<TMPL_VAR NAME="file_uri" ESCAPE="HTML">"><TMPL_VAR NAME="file_uri" ESCAPE="HTML"></a>> + </TMPL_IF> </TMPL_IF> <TMPL_IF NAME="is_tentative"> was checked and found to be <em>tentatively</em> valid <TMPL_VAR NAME="file_version" ESCAPE="HTML">. @@ -90,6 +94,7 @@ </p> </TMPL_IF> <TMPL_UNLESS NAME="is_upload"> + <TMPL_UNLESS NAME="is_direct_input"> <h4>Linking to this result</h4> <p> If you would like to create a link to <em>this</em> page (i.e., this @@ -98,6 +103,7 @@ <<a href="<TMPL_VAR NAME="file_thispage" ESCAPE="HTML">"><TMPL_VAR NAME="file_thispage" ESCAPE="HTML"></a>> (or you can just add the current page to your bookmarks or hotlist). </p> + </TMPL_UNLESS> </TMPL_UNLESS> <h4>Validating CSS Style Sheets</h4> <p> @@ -106,9 +112,12 @@ <TMPL_IF NAME="is_upload"> check it for validity <TMPL_ELSE> + <TMPL_IF NAME="is_direct_input"> + <TMPL_ELSE> <a title="Validate CSS at the W3C CSS Validator" href="http://jigsaw.w3.org/css-validator/validator?uri=<TMPL_VAR NAME="file_uri_param">">check it for validity</a> + </TMPL_IF> </TMPL_IF> using the W3C <a href="http://jigsaw.w3.org/css-validator/">CSS Validation Service</a>. Index: table.tmpl =================================================================== RCS file: /sources/public/validator/share/templates/en_US/table.tmpl,v retrieving revision 1.30 retrieving revision 1.31 diff -u -d -r1.30 -r1.31 --- table.tmpl 11 Sep 2007 04:44:49 -0000 1.30 +++ table.tmpl 12 Sep 2007 06:09:40 -0000 1.31 @@ -19,7 +19,11 @@ <TMPL_IF NAME="is_upload"> <form id="form" method="post" action="check"> <TMPL_ELSE> -<form id="form" method="get" action="check"> + <TMPL_IF NAME="is_direct_input"> + <form id="form" method="post" action="check"> + <TMPL_ELSE> + <form id="form" method="get" action="check"> + </TMPL_IF> </TMPL_IF> <table class="header"> <tr> @@ -40,11 +44,20 @@ </tr> <tr> <TMPL_IF NAME="is_upload"> - <th>Uploaded Content:</th><td colspan="2"><textarea id="fragment" name="fragment" rows="12" cols="80"><TMPL_LOOP NAME="file_source"><TMPL_VAR NAME="file_source_line" ESCAPE="HTML"> -</TMPL_LOOP></textarea></td> + <th><label title="Choose a Local File to Upload and Validate" for="uploaded_file">File</label>:</th> + <td colspan="2"> + <p>If you wish to re-validate an uploaded file, please select it again here:</p> + <input type="file" id="uploaded_file" name="uploaded_file" size="30" /> + </td> + <TMPL_ELSE> + <TMPL_IF NAME="is_direct_input"> + <th><label title="Uploaded source of your Document" for="fragment">Source</label>:</th><td colspan="2"><textarea id="fragment" name="fragment" rows="12" cols="80"><TMPL_LOOP NAME="file_source"><TMPL_VAR NAME="file_source_line" ESCAPE="HTML"> + </TMPL_LOOP></textarea></td> + <TMPL_ELSE> <th><label title="Address of Page to Validate" for="uri">Address</label>:</th> <td colspan="2"><input type="text" id="uri" name="uri" value="<TMPL_VAR NAME="file_uri" ESCAPE="HTML">" size="50" /></td> + </TMPL_IF> </TMPL_IF> </tr> <TMPL_IF NAME="opt_verbose">
Received on Wednesday, 12 September 2007 06:09:46 UTC