Re: How TO - Include HTML

On 8 Jul 2016, at 17:46, V G Woodhouse wrote:
> Error: Attribute w3-include-html not allowed on element div at this point.

> I have used code equivalent to w3schools example, reproduced below,  and have been unable to clear validation.

W3Schools are awful (and not related to the W3C) and the guide you followed requires you to write invalid HTML.

HTML 5 provides [data attributes][1] for this kind of extension, and the script you are using should have been written to use them.

I'd recommend against using client side JavaScript for this sort of thing and pick a solution that runs either server side or with a preprocessor at build time.

[1]: https://www.w3.org/TR/html5/dom.html#embedding-custom-non-visible-data-with-the-data-*-attributes

-- 
David Dorward
http://dorward.co.uk/

Received on Tuesday, 12 July 2016 14:44:46 UTC