Nalaka526
Nalaka526

Reputation: 11464

Is it possible to add style sheet only to a content page?

In a asp.net webforms project, I need to add external style sheet only to content page,

If I put css link after the <%@ Page> declaration it gives an error saying

Error   103 Validation (XHTML 1.0 Transitional): Content is not supported outside 'script' or 'asp:content' regions.

If I put it inside <asp:Content> tag error is

Error   104 Cannot switch views: Validation (XHTML 1.0 Transitional): Element 'link' cannot be nested within element 'td'.

Is it possible to add a style sheet only to content page?

Upvotes: 0

Views: 1487

Answers (1)

Thanh Nguyen
Thanh Nguyen

Reputation: 1056

You should create a place holder in the head section in master page. Then in the content page, if you want to include js, css, ... put on this place holder, unless keep it empty.

Upvotes: 4

Related Questions