Struggling with properly applying quotation marks around IDs and Bootstrap formatting.
The HTML snippet should resemble this:
<tr>
<th scope="row">1</th>
<td>HOU</td><td>-9.8</td>
<td id="odds-1">2</td>
<td id="place-bets-1">
<button class="btn btn-primary my-2 my-sm-0 pb" id="pick-team-1">Select</button>
</td>
</tr>
Make sure to include quotes around:
- "row"
- "odds-1"
- "place-bets-1"
- "btn btn-primary my-2 my-sm-0 pb"
- "pick-team-1"
JS Code
$("#nflteams").append("<tr><th scope=row>" + i + "</th><td>" + response[i].HomeTeam + "</td><td>" + response[i].PointSpread +
"</td><td id=odds-" + i + "1>2</td><td id=place-bets-" + i + "><button class=btn btn-primary my-2 my-sm-0 pb id=pick-team-" + i + ">Select</button></td></tr>")
I've heard that escaping strings with "\" should work, but Visual Studio Code is showing an error when I attempt it in the IDs and bootstrap formatting.