3
You cannot use a standard GET request. You must obtain the access_token and then POST the necessary parameters.
The steps are currently:
Setup:
Register your app.
Link it with a post here on Stack Apps that has a legitimate [app] or [script] tag. In most cases you will also tag it with placeholder.
In your app:
Have the user authorize your app and ...
2
First can I say, you might want to use your own icon. Font Awesome is a very useful and easy to use icon toolkit that lets you add icons with simple CSS classes. You could use http://fontawesome.io/icon/star/ if you want :)
However, if you want to use SE's button, in Javascript, if you want to override an event handler, you need to return false; or call ...
1
Don't use the default button. That's bad UI anyway.
Add your own favorite button for each answer.
And, since you will be using your own classes, like:
<a class="myStarOff" href="#" data-ansID="1234" title="Click to add as favorite answer (click again to undo)">
favorite</a>
<a class="myStarOn" href="#" data-ansID="56789" title="Click to ...
Only top voted, non community-wiki answers of a minimum length are eligible
Related Tags
favorite × 6support × 2
app × 2
script × 2
api × 1
discussion × 1
obsolete × 1
website × 1
answers × 1
greasemonkey × 1
tampermonkey × 1
stackoverflow × 1
scripts × 1
write-access × 1