I'm trying to put a php variable in a button data attribute however weird characters are showing up instead of the punctuation. As an example instead of an apostraphe '
is showing up instead. The variable is normal everywhere else on the page. How can I fix this?
<button id="coolButton"data-name="<?PHP echo $name;?>"