Custom Javascript to run on one page only
-
Hello. Running a local WordPress site on Xampp currently. Using a Twenty Nineteen child theme. We are trying to install the custom javascript located here: https://auz.github.io/Bug/
We want this to run on only one of our WordPress pages. Currently the JS files are located in twentynineteen-child/js. We haven’t been able to successfully get this to run using any recommended plug-in methods that we’ve found. There are varying functions.php resolutions we’ve found out there but we’re not sure which method to use. We’re also not sure whether to just link to the javascript, what link we would use (since it’s local) or to just paste the entirety of the code in (it’s pretty long) We did try the solution listed on WP Beginner for adding a script to one page but keep getting a parsing error when using that code. Any ideas? We’re new to adding JS to WordPress. Thank you.
The topic ‘Custom Javascript to run on one page only’ is closed to new replies.