开发者

How to create HTML5 data-* in MVC3

I'm using JQuery mobile and I need to include data-prefetch attribute in a link created with HTML.ActionLink. I've found examples on Stackoverflow of how to pass data-* attributes in the standard way with object Html att开发者_JAVA百科ributes. However I can't seem figure out how to create an attribute that has no value. Best I can create is data-prefetch="" by using new{data_prefetch=""} . I'm assuming that isn't the same.

Any ideas?


As far as I can see using data-prefetch="data-prefetch" works fine. So I guess there is no need to do anything else.

Thanks feeela

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜