Eugene Yarmash
Eugene Yarmash

Reputation: 149726

Is it ok to place link elements outside document's head section?

It's stated that the link element must be embedded in the head section.

I need to link some style sheets to a document with static predefined header (rendered by legacy framework). So I can't insert the tags to the head. Can placing them outside cause issues with any browsers ? Or maybe its better to insert the tags with javascript ?

Upvotes: 0

Views: 853

Answers (2)

DalSoft
DalSoft

Reputation: 11088

Don't do it especially on a website as opposed to a intranet. You will start to limit what browsers can view your site correctly. Please could you elaborate on your usage, I bet there is a better solution to the problem you are trying to solve.

Upvotes: 0

Quentin
Quentin

Reputation: 943099

No version of HTML allows it, but browsers perform a great deal of error recovery. I wouldn't depend on it.

Upvotes: 5

Related Questions