I ended up with this code and have added the two jquery files into the SharePoint site.
Obviously, I usually have the full links at the top, but I've taken the first part of it out for privacy reasons. I believe I linked everything in my site correctly, because when I click the button I've added, I get the alerts listed within the script and within both of the functions, meaning they're being triggered. However, the workflow doesn't run. I have checked multiple times that the template ID is correct, and I'm at a loss as to where this could be going wrong. The workflow runs when I trigger it the normal way (through the workflows button), but running it using this script does not work.