开发者

Attribute "runat" is not a valid attribute. Did you mean "content" or "target"? How to solve this asp.net validation error

开发者 https://www.devze.com 2022-12-12 08:25 出处:网络
see here this error - http://validator.w3.org/check?verbose=1&开发者_运维技巧amp;uri=http%3A%2F%2Fwww.sitecore.net%2Frunat=\"server\" is asp.net server control syntax. It must not come in html. It is

see here this error - http://validator.w3.org/check?verbose=1&开发者_运维技巧amp;uri=http%3A%2F%2Fwww.sitecore.net%2F


runat="server" is asp.net server control syntax. It must not come in html. It is interpreted by ASP.NET. you must remove this attribute.
Possible Reason for this:
1. I think the template is dynamically created. the developer make static site and cut copy paste on server side to make it dynamic but use control as response.write and forgot to remove runat="server" because it must be html content in response.write.

NOTE: No ASP.NET server control gives runat="server" in HTML. It is hardcoded in your code. remove this from both anchor and image tag.


Er... remove the attributes? They aren't valid HTML, and they're only meaningful when interpreted by ASP.NET.


Your pages should not be rendered with runat="server", so something's definitely going wrong here. What does the part of your aspx look like, that corresponds to one of the elements that is giving this validation error?

0

精彩评论

暂无评论...
验证码 换一张
取 消