From the course: WordPress: Customizing Themes with Genesis

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Action hooks and filters in WordPress

Action hooks and filters in WordPress

From the course: WordPress: Customizing Themes with Genesis

Start my 1-month free trial

Action hooks and filters in WordPress

- [Instructor] In this movie, I'd like to introduce you to the Wordpress Plugin API. Now, you may be saying whoa, whoa, whoa Carrie. We're talking about themes, not plugins, but I promise you this is relevant. The plugin API is made up of hooks of which there are two types. Actions and filters, and these are what let us hook into Wordpress. These hooks give us the ability to write a bit of code that communicates with Wordpress. What do I mean by that? Well, Wordpress is code, right? When you login to your Wordpress admin, there's some code that runs. If you publish a post, there's a bit more and if someone leaves a comment, there's more code that runs that still. So, everything that happens in Wordpress, obviously, there's code behind it to make it happen. But hooks are present throughout Wordpress code and these let us latch on to a particular process that happens and then run our code at that moment. And this is…

Contents