The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Valid XHTML 1.0 error question
Can anyone tell me why this line is not passing XML validation and how to fix it? I can get rid of the error if I use span instead of div but I need the padding for these links.
HTML Code:
<strong><div style="padding:4px;0px;4px;0px;"><a class="sitemap" href="' . $vbulletin->options['bburl'] . '/forumdisplay.php?f=' . $forumid . '" style="font-weight:bold;font-size:12px;" title=" ' . $forum[title] . ' ">'; Quote:
|
#2
|
||||
|
||||
try to move the div tag outside of the <strong> tag and be sure to close the strong and div tags
and your padding: markup is wrong i think, shouldn't it be Code:
padding: 4px 0px 4px 0px; |
#3
|
||||
|
||||
Both ways seem to work on the padding and it gives no error. But I changed it to your way if that is the right way.
Thank you, sir, that fixed it. I didn't know validation could be so touchy on such minor things. Now I've got the home page and the site map all validated for XHTML 1.0 and CSS. I've been having a blast fixing the errors as I find them (I really need to get out more I think). The default vb skin even had a few minor ones. |
#4
|
||||
|
||||
Good to know the padding used that way works though first time i've seen it coded that way
|
#5
|
||||
|
||||
I'm a coding pioneer.
Thanks again for the help. I'm on a quest to get the whole site validated. I may pop back in here if I run into any problems. I reported one from the search_forums to the com. It seems they use autocomplete= in there and the validation doesn't like that. |
#6
|
||||
|
||||
your problem was that you were trying to embed a block-level element within an inline element
I suggest the following: HTML Code:
<div style="padding:4px;0px"> <a href=""> <strong>title</strong> </a> </div> HTML Code:
<h2> <a href="">title</a> </h2> |
#7
|
||||
|
||||
The first code is basically what I went with. So my padding code was right then?
What does the <h2> do? |
#8
|
|||
|
|||
|
#9
|
||||
|
||||
I tried the <h2> tags and they did great for the bold part but did way too much vertical spacing. I'll keep those in mind though, thanks!
|
#10
|
|||
|
|||
You can style your h1, h2, etc. tags via CSS to make them smaller, larger or whatever. For instance, you can add the following to the Additional CSS Definitions in your Style Manager:
h2 { font-size: 10pt; } |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|