Step #1 – Enqueue scripts in functions.php
Step #2 – JavaScript
Step #3 – Callback function
functions.php
functions.php
I'm a web developer and designer based in Budapest, Hungary. In recent years, I've documented hundreds of solutions I came across during development. This site is an archive for useful code snippets on WordPress, Genesis Framework and WooCommerce. If You have any questions related to WordPress development, get in touch!
Alessio Frugoni says
I entered the code but it does not work as seen in the example. As soon as I click on a category it opens the category page. Instead I would like you to show me the articles belonging to that category. I’m sure I’m wrong but I can’t understand. Thanks
Gabor says
Please make sure the jquery is not duplicated in your theme’s functions.php.