I have a checkbox like this:
<li> <input type="checkbox" name="collection[1]" value="1234"/>test</li>
When I use $(this).text()
it should return "test"
but it's returning " test"
(ie. with multiple spaces at the beginning)
I also checked the innerText
property it has value as "test"
.