Page 1 of 1
free tag frontend HTML does not validate?
Posted: Sun Nov 20, 2005 12:33 am
by zoran
When I try to validate my page at the w3c validator, I get errors on all serendipity_freetag divs. I'm not into css, can somebody point out what's wrong with the nesting?
This is the nesting:
Code: Select all
<div class="entrytext"><p class="postmetadata"><small><div class="serendipity_freeTag"></div></small></p></div>
This is the validator result:
http://validator.w3.org/check?uri=http% ... =1#line-68
Best, Zoran
Posted: Sun Nov 20, 2005 11:47 pm
by MySchizoBuddy
ur using an old version of it
i beleive this problem has already been fixed.
Re: free tag frontend HTML does not validate?
Posted: Mon Nov 21, 2005 12:32 pm
by garvinhicking
Actually this is not a problem of the plugin, but of the Kubrick template. It uses a "<small>" Tag which is a non-block element. But block elements often occur within Sidebars.
So the best thing is to replace the <small> tag within sidebar.tpl (?) with a <div class="small"> or so, and style it with CSS...
Regards,
Garvin
Posted: Mon Nov 21, 2005 6:18 pm
by zoran
Hi Garv,
I changed the <p> tag into a <div> tag and did some stylesheet changes, and it works now. Should I commit this in CVS?
Now I try to validate the CSS:
http://jigsaw.w3.org/css-validator/vali ... c.nl/blog/
This give the error
Code: Select all
Line: 2 Context : img
Property behavior doesn't exist : url("http://www.kovacevic.nl/blog/plugin/pngbehavior.htc")
Any idea what that does?
Regards, Zoran
Posted: Mon Nov 21, 2005 7:28 pm
by garvinhicking
Which patch did you do exactly?
About the .htc thing: This is required for browser compatibility so that IE can display transparent PNG images. It cannot be done in a W3C validating way.
Regards,
Garvin
Posted: Mon Nov 21, 2005 8:38 pm
by zoran
I basically replaced the small with a div tag. Where a p tag was present, I replaced that with a div and removed the small. Added the small style definition from the css to the containing element. More or less
I changed these files:
Code: Select all
$ diff fresh/comments.tpl kubrick/comments.tpl
9c9
< <small class="commentmetadata">
---
> <div class="commentmetadata">
18c18
< </small>
---
> </div>
Code: Select all
$ diff fresh/entries.tpl kubrick/entries.tpl
8c8
< {if !$is_single_entry}<small>{$entry.timestamp|@formatTime:DATE_FO
RMAT_ENTRY}</small>{/if}
---
> {if !$is_single_entry}<div class="small">{$entry.timestamp|@format
Time:DATE_FORMAT_ENTRY}</div>{/if}
32,33c32
< <p class="postmetadata{if $is_single_entry} graybox{/if}">
< <small>
---
> <div class="postmetadata{if $is_single_entry} graybox{/if}">
82,83c81
< </small>
< </p>
---
> </div>
Code: Select all
$ diff fresh/trackbacks.tpl kubrick/trackbacks.tpl
5c5
< <small class="commentmetadata">
---
> <div class="commentmetadata">
11c11
< </small>
---
> </div>
and style.css, but unfortunately diff considers the whole file different (any ideas which switches to use to prevent this?), so please check this deeplink:
http://www.kovacevic.nl/blog/templates/ ... /style.css
Zoran
P.S.: Too bad about the MSIE hack
Posted: Mon Nov 21, 2005 10:18 pm
by garvinhicking
Zoran,
the patch is fine with me, do you have a SVN (not CVS!) account so you can commit it to trunk? If not, I can give you one if you get yourself a
www.berlios.de account
The full file difference in style.css can come because the file currently may have windows linebreaks instead of unix linefeeds?
Regards,
Garvin
Posted: Thu Nov 24, 2005 9:19 pm
by zoran
patch commited in SVN