I have some PHP and HTML:
<div class="bought">
<div class="row">
<div class="col">
<div class="body">
<?php if(Request::is('user/*')) { ?>
<div>Did you buy this for <?php echo $user->username ?>?</div>
<div class="options">
<a class="boughtyes cbutton whiteonpurple">Yes</a>
<a class="boughtno cbutton whiteonpurple">No</a>
</div>
<?php } else { ?>
<div>Bought?</div>
<p>Click here to send hinters a message to let them know.<br />And yes, it can still be a surprise!</p>
<?php } ?>
</div>
</div>
</div>
</div>
And some jQuery that is supposed to simply bring up a JavaScript window with no or yes based on selection:
$("#view-hint .img .bought .boughtyes").click(function() {
window.alert("yes");
});
$("#view-hint .img .bought .boughtno").click(function() {
window.alert("no");
});
But whether I click the yes or no button it returns 'yes':
What am I doing wrong?
EDIT: