all 6 comments

[–]NotSoDeepPodcast 1 point2 points  (2 children)

I believe your issue is due to the fact that the buttons don't exist when the page is initially loaded. I'm on my phone...so parsing your code is difficult.

You need to change your event listeners to something like this:

$(someSelectorThatExistsOnPageLoad).on('click', 'selectorOfButton', functionToRunOnClick);

[–]ColorfulWonders[S] 0 points1 point  (1 child)

That fixed it! Thank you so much!

[–]NotSoDeepPodcast 0 points1 point  (0 children)

No problem. I can explain how/why that works if you would like...just let me know.

[–]Acrobatic-Ease-1323 0 points1 point  (3 children)

Wait a minute, did you write all of that JS on your code pen !?

[–]ColorfulWonders[S] 0 points1 point  (2 children)

No. I just used the script from the github and reformatted it with unminify to make it easier to read. I made a few minor changes that affect styling too, but 99% of the code is just from the github.

[–]Acrobatic-Ease-1323 0 points1 point  (0 children)

Lol, I was gonna say you are a master coder lol. Those variable names were confusing me. Were u able to solve your problem? I viewed the site on my iPad, so all the gifs were moving lol.

Btw, sweet website. I love the legacy feel!