This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.
n30h.slyfo4920
I d like to make a button which calls a function in my plugin component.
This is what im using now
{{ form_open({ request: 'upVote' }) }}
<button class="btn" type="submit" >+</button>
{{ form_close() }}
Id like to call upVote function without the form and without refreshing the page
Scott
Try renaming your ajax method to use the "onName" convention (http://octobercms.com/docs/cms/ajax#ajax-handlers), then give this code a try
<a href="#" data-request="onUpVote">+</a>
1-6 of 6