mark: A photo of Mark kneeling on top of the Taal Volcano in the Philippines. It was a long hike. (Default)
Mark Smith ([staff profile] mark) wrote in [site community profile] changelog2009-02-27 02:21 am

[dw-free] Javascript/HTML standard nitpickiness in weblib.pl

[commit: http://hg.dwscoalition.org/dw-free/rev/1b4fccffe0dc]

http://bugs.dwscoalition.org/show_bug.cgi?id=332

HTML validation update and fix condition.

This patch was pulled from the LiveJournal.com repository.

Patch by [staff profile] denise.

--------------------------------------------------------------------------------
diff -r 8f420118d51d -r 1b4fccffe0dc cgi-bin/weblib.pl
--- a/cgi-bin/weblib.pl	Fri Feb 27 02:12:31 2009 +0000
+++ b/cgi-bin/weblib.pl	Fri Feb 27 02:21:25 2009 +0000
@@ -2144,14 +2144,14 @@ sub res_includes {
 
     # include standard JS info
     $ret .= qq {
-        <script language="JavaScript" type="text/javascript">
+        <script type="text/javascript">
             var Site;
             if (!Site)
                 Site = {};
 
             var site_p = $site_params;
             var site_k = $site_param_keys;
-            for (var i = 0; i < site_k.length; i++) {
+            for (var i = 0; site_k.length > i; i++) {
                 Site[site_k[i]] = site_p[site_k[i]];
             }
        </script>
--------------------------------------------------------------------------------

Post a comment in response:

This account has disabled anonymous posting.
If you don't have an account you can create one now.
HTML doesn't work in the subject.
More info about formatting

If you are unable to use this captcha for any reason, please contact us by email at support@dreamwidth.org