Hi,
I've spotted this while validating my websites with http://validator.w3.org.
For example, if you attempt to validate http://www.sytru.com/ which is using Views to display the front page results you'll end up with the following validation error:
Line 108, Column 88: document type does not allow element "div" here; missing one of "object", "ins", "del", "map", "button" start-tag.
…iew-display-id-default view-dom-id-1">
The mentioned element is not allowed to appear in the context in which you've placed it; the other mentioned elements are the only ones that are both allowed there and can contain the element mentioned. This might mean that you need a containing element, or possibly that you've forgotten to close a previous element.
One possible cause for this message is that you have attempted to put a block-level element (such as "<p>" or "<table>") inside an inline element (such as "<a>", "<span>", or "<font>").
Can you please correct this in the next version of Views?
Thanks,
s
Comments
Comment #1
merlinofchaos commentedCorrect what? You give a tiny fragment of HTML. How do I know you didn't foolishly put your view inside a span tag and are blaming the module for it?
Comment #2
nrackleff commentedI am having the same problem. Here is the code generated by the view:
I am using Views 6.x-2.6 and using Fields to create the view. I do not have 'inline' checked for any fields in the view. Is there any way to change the 'span class="field-content"' to div class="field-content"'?
Please let me know if you need any more information. Thanks for your help.
Comment #3
merlinofchaos commentedSearch the CCK queue -- it is what sets a field as block/inline for the span/div. You can override this in the templates (see theme: information to see what the templates are/do and see the advanced help for some information about using them)
Comment #4
esmerel commentedNo updates for more than 30 days.