Click here to Skip to main content
15,891,777 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello every body

i create label and text box in my project in asp.net mvc

the dir is rtl , i want the label in the right side how i can but the label and text box beside each other

This is design and code :

https://www8.0zz0.com/2019/05/24/14/372064465.png[^]

What I have tried:

@using (Html.BeginForm())
{
    @Html.AntiForgeryToken()

    <div dir="rtl">

        <div class="form-horizontal">
            <h3>Create</h3>
            <hr />
                        <div class="form-border">
                            <div class="form-group">
                               @Html.LabelFor(model => model.Name, htmlAttributes: new { @class = "control-label col-md-2 " })
                                <div class="col-md-8">
                                    @Html.EditorFor(model => model.Name, new { htmlAttributes = new { @class = "form-control" } })
                                    @Html.ValidationMessageFor(model => model.Name, "", new { @class = "text-danger" })
                                </div>
                            </div>
                    </div>
                </div>
            </div>
Posted
Updated 24-May-19 1:33am
v4
Comments
Richard Deeming 24-May-19 13:50pm    
Bootstrap doesn't have RTL support yet. There's a few relevant discussions on their GitHub repository - for example:
Final RTL discussion · Issue #28797 · twbs/bootstrap[^]

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900