Invalid anonymous type member declarator using data-url html attribute

后端 未结 1 1679
轻奢々
轻奢々 2021-01-05 12:32

I am making a small project using jQuery, MVC4 with Razon and C#. In my view I have a drop down list and I wish to give it the attribute of data-url=Url.Action(\"Upda

相关标签:
1条回答
  • 2021-01-05 13:07

    data-url is not a valid C# identifier.

    Instead, use data_url.
    MVC will replace _ with -.

    0 讨论(0)
提交回复
热议问题