Good afternoon, I'm trying to build a table with Bootstrap and would like to change the label type, depending on what was written inside the cell.
Table example:
<table>
<tr>
<td><span class="label label-primary">Texto</span></td>
</tr>
</table>
Status: If instead of "Text" it was written "Ball", I wanted to be able to change the label from "primary" to "success" or any other type, and I have no idea how to achieve this result. p>
Thanks for any help with this code, as I'm a beginner with JavaScript.