- Posts: 32
COMMUNITY FORUM
- Forum
- Free Joomla Extensions & Templates
- Simple Image Gallery
- W3C Validation Issue - slightly resolved but still need help!
W3C Validation Issue - slightly resolved but still need help!
- LukeDouglas
-
Topic Author
- Offline
- Junior Member
Less
More
14 years 6 months ago - 14 years 6 months ago #35611
by LukeDouglas
W3C Validation Issue - slightly resolved but still need help! was created by LukeDouglas
I have reviewed every post concerning getting this plug-in to validate on the W3C Validator and can not resolve this problem.
This is the page I am testing as I use this plug-in and if I can get this 'multiple galley' page to validate, the others will be a breeze: ampmdesignstudio.com/am-pm-design-studios Here is the validator URL: validator.w3.org/check?uri=http%3A%2F%2Fampmdesignstudio.com%2Fam-pm-design-studios&charset=%28detect+automatically%29&doctype=Inline&ss=1&group=0&user-agent=W3C_Validator%2F1.1
If anyone knows a 'quick fix', I would surely appreciate it!
Now on this date, Sept 22, 2010, I get 481 Errors, 786 warning(s). I know that part of this is due to the Tabs & Slides plug-in but let's forget that for right now. On one of the articles, I replaced the '{gallery}' with '{vsig}' using the Very Simple Image Gallery plug-in. When I re-validate, I get 301 Errors, 480 warning(s). That is a 38% decrease in the number of errors on just one article with galleries using a different gallery plug-in.
So I could just use the Very Simple Image Gallery instead of the Simple Image Gallery BUT I would prefer to use this plug-in as it just looks better.
I looked at the jwsig.php file and centered my research on what I believe is one of these error's and that is the internal style code to set the height and width of '.sig_cont'.
I played around with this trying to encapsulate it inside a script which still worked but, alas, got the same number of errors.
So I then tried to encapsulate it into PHP.
The page still works, although it displays 'document.write(""); ?>' just before the gallery, AND it does reduce the errors on the Validator to 462 Errors, 786 warning(s). That is 19 fewer errors on just one article or about 4 per gallery. If someone can tell me why the 'document.write(""); ?>' is displaying on the page, I can do some further testing.
Please note that with the 19 galleries, I suspect that about 76 of the total errors are due to this one line on the SIG plugin.
Finally, I installed the SigPlus Image Gallery which uses the same '{gallery}' tags, I enabled it, disabled the Simple Image Gallery and 'viola', the number of errors on the Validator page is now 4 Errors with no warnings. The only problem is the Tabs & Slides due to the use of 'ID' instead of 'Class'.
Not sure what the developers were thinking in using 'ID' versus 'Class' as it does cause this problem if you have multiple Tabs and Slides on a single page IF no 'ID' is set.
I edited the 'jwts.php' at about line #112:
Changed:
To:
As there were 'no' CSS settings for "#jwts_tab" with or without any 'ID #', this didn't cause a problem but if anyone does have any CSS settings, just copy them and set it to ".jwts_tab" with any 'ID #' that may be suffixed.
Now the page validates with NO ERRORS! :D
But I still would like to use the Simple Image Gallery if anyone has any suggestions.
Rome wasn't built in a day. :(
This is the page I am testing as I use this plug-in and if I can get this 'multiple galley' page to validate, the others will be a breeze: ampmdesignstudio.com/am-pm-design-studios Here is the validator URL: validator.w3.org/check?uri=http%3A%2F%2Fampmdesignstudio.com%2Fam-pm-design-studios&charset=%28detect+automatically%29&doctype=Inline&ss=1&group=0&user-agent=W3C_Validator%2F1.1
If anyone knows a 'quick fix', I would surely appreciate it!
Now on this date, Sept 22, 2010, I get 481 Errors, 786 warning(s). I know that part of this is due to the Tabs & Slides plug-in but let's forget that for right now. On one of the articles, I replaced the '{gallery}' with '{vsig}' using the Very Simple Image Gallery plug-in. When I re-validate, I get 301 Errors, 480 warning(s). That is a 38% decrease in the number of errors on just one article with galleries using a different gallery plug-in.
So I could just use the Very Simple Image Gallery instead of the Simple Image Gallery BUT I would prefer to use this plug-in as it just looks better.
I looked at the jwsig.php file and centered my research on what I believe is one of these error's and that is the internal style code to set the height and width of '.sig_cont'.
<style type="text/css">.sig_cont {width:'.($_width_+30).'px;height:'.($_height_+20).'px;}</style>
I played around with this trying to encapsulate it inside a script which still worked but, alas, got the same number of errors.
$html .='<script type="text/javascript">document.write("<style type="text/css">.sig_cont {width:'.($_width_+30).'px;height:'.($_height_+20).'px;}</style>"); </script>';
So I then tried to encapsulate it into PHP.
$html .='<?php <script type="text/javascript">document.write("<style type="text/css">.sig_cont {width:'.($_width_+30).'px;height:'.($_height_+20).'px;}</style>"); </script> ?>';
The page still works, although it displays 'document.write(""); ?>' just before the gallery, AND it does reduce the errors on the Validator to 462 Errors, 786 warning(s). That is 19 fewer errors on just one article or about 4 per gallery. If someone can tell me why the 'document.write(""); ?>' is displaying on the page, I can do some further testing.
Please note that with the 19 galleries, I suspect that about 76 of the total errors are due to this one line on the SIG plugin.
Finally, I installed the SigPlus Image Gallery which uses the same '{gallery}' tags, I enabled it, disabled the Simple Image Gallery and 'viola', the number of errors on the Validator page is now 4 Errors with no warnings. The only problem is the Tabs & Slides due to the use of 'ID' instead of 'Class'.
Line 351, Column 32: ID "jwts_tab" already defined
<div class="jwts_tabber" id="jwts_tab"><div class="jwts_tabbertab" title="Set…
An "id" is a unique identifier. Each time this attribute is used in a document it must have a different value. If you are using this attribute as a hook for style sheets it may be more appropriate to use classes (which group elements) than id (which are used to identify exactly one element).
Not sure what the developers were thinking in using 'ID' versus 'Class' as it does cause this problem if you have multiple Tabs and Slides on a single page IF no 'ID' is set.
I edited the 'jwts.php' at about line #112:
Changed:
<div class=\"jwts_tabber\" id=\"jwts_tab".$tabid."\"><div class=\"jwts_tabbertab\" title=\"".$match."\"><h2><a href=\"javascript:void(null);\" name=\"advtab\">".$match."</a></h2>", $row->text );
To:
<div class=\"jwts_tabber jwts_tab".$tabid."\"><div class=\"jwts_tabbertab\" title=\"".$match."\"><h2><a href=\"javascript:void(null);\" name=\"advtab\">".$match."</a></h2>", $row->text );
As there were 'no' CSS settings for "#jwts_tab" with or without any 'ID #', this didn't cause a problem but if anyone does have any CSS settings, just copy them and set it to ".jwts_tab" with any 'ID #' that may be suffixed.
Now the page validates with NO ERRORS! :D
But I still would like to use the Simple Image Gallery if anyone has any suggestions.
Rome wasn't built in a day. :(
Please Log in or Create an account to join the conversation.
- Forum
- Free Joomla Extensions & Templates
- Simple Image Gallery
- W3C Validation Issue - slightly resolved but still need help!