jdm/asknot — pull request #216 by matthewsot (2014-07-25 07:46:50+00:00)
Title: 'Open in new tab' and 'copy link' on the buttons - issue #215

This PR adds the correct hrefs to all of the buttons, so users can do things like middle clicking, open in new tab, copy link, etc.

I also moved the code for incrementing choiceIndex into it's own function so it could be referenced by both nextChoice (as it was before) and updateCurrentChoice (to get a link for the 'next' button).

Last thing to mention would be that I named the next choice variable 'nextChoice' to keep in line with the naming of lastChoice, but that could cause some problems if someone ever decides to call nextChoice (the function) from within updateCurrentChoice.

Tested in IE 11.0.9600.17207, Nightly 34.0a1 (2014-07-24), and Chrome 35.0.1916.114m