Basically what is happening is when I press the button then I get a +1 point on post. Everything is working excellent but I don't know how to update the number itself without page refresh. The info is already send to database I just don't know how to change number without page refresh.. This is my jQuery:
$(document).ready(function(){
$('form').submit(function(evt){
evt.preventDefault();
var url = $(this).attr("action");
var formData = $(this).serialize();
$.get(url, formData, function(response){
});
});
});
And my html:
<p>Not recommended: <strong><span id="votes" class="label label-success">{{$s->points}}</span></strong></p>