This project is read-only.

DotNetNuke DDRMenu and W3C Validation..

Dec 6, 2011 at 12:52 PM

Hi guys,

Thanks for your work on such a great menu system! Have been using DNN a long time, and this is by far the best.

Im having some W3c validation errors on mine though, and wanted to ask if you could offer any advice to get it 100% w3C happy?

The error is...

Line 142, Column 74document type does not allow element "div" here; missing one of "object", "applet", "map", "iframe", "button", "ins", "del" start-tag


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>").

Its from a bog standard installation of DNN, with the DarkKnight skin (cutup so it works for me - but I havent touched DDRMenu).

Any help appreciated! Thanks!!

Oct 23, 2012 at 4:25 PM


you need to replace the div whihc is around the page name with span (a is a inline element and XHTML does not allow to include a block element such as div). Having said that, I don't know where to fix that in the code. The CSS bit is easy.

Will there be an updated release thta makes it compliant?


Oct 26, 2013 at 6:12 PM
You can't have block elements (div,p,etc.) inside inline elements (span,a,etc.). So you currently have <a><div>...</div></a>. Instead you need <div><a>...</a></div> or <a><span>...</span></a>.

You would need to change this in your template file. What type of template are you using (token,XSLT, or Razor)?