Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Remove Bullets from @Html.ValidationSummary() in MVC4

How can I remove remove bullets from @Html.ValidationSummary() in MVC4. Any suggestions?

<span class="help-block" style="list-style-type: none;"> 
    @Html.ValidationSummary() 
</span>
like image 593
Naveen Avatar asked Mar 26 '15 09:03

Naveen


2 Answers

Given that your comment describes your code like this:

<span class="help-block">
    @Html.ValidationSummary() 
</span>

You can set the CSS property list-style-type to none on the ul element which the ValidationSummary generates. Try this:

.help-block ul {
    list-style-type: none;
}
like image 145
Rory McCrossan Avatar answered Sep 29 '22 10:09

Rory McCrossan


.validation-summary-errors ul { 
    list-style: none;
    margin-left:-40px
}
like image 39
Sh7ne Avatar answered Sep 29 '22 10:09

Sh7ne