右对齐 HTML 中的文本.文本框



我正在使用Twitter Bootstrap,带有 ASP.Net MVC。

如何右对齐文本框中的文本:

@Html.TextBoxFor(model => model.PaymentReceived, 
new { @class = "pmtallocated pull-right" , .dir = "rtl" })

我在上面尝试时收到错误Invalid expression term '.'

谢谢

马克

试试

new { @class = "pmtallocated pull-right" , @dir = "rtl" })

尝试任何

@Html.TextBoxFor(model => model.PaymentReceived, 
new { @class = "pmtallocated pull-right" , @dir = "rtl" })

@Html.TextBoxFor(model => model.PaymentReceived, 
new { @class = "pmtallocated pull-right" , @style="text-align:right"})

最新更新