[Video]—A Beginner’s Guide To Using WordPress Hooks

Web-designers-toolkit

WordPress is one of the most user-friendly CMSes out there. And one of the reasons of WordPress’s popularity are the themes. You can customize these as you like and make WordPress truly yours…

However when you come across issues you need help. And there certainly is a learning curve involved. Sometimes it’s easy to get help and sometimes it just a long wait. Also most of the beginners come from a non-technical background.

Once you receive help you move on and then again you stumble across a hurdle and you need help again. Such help does get you going but does not make you a problem solver in the long run.

Also it so happens that we try to avoid code since that makes us uncomfortable. But the fact is that if you want to become a real developer some day, you’ll have to get into the code because there’s no software that can replace code.

Expectations from this video

My attempt with this video is to share some tips on how you can get into the developer mode yourself. Because as the adage goes… give a man a fish and you feed him for a day; teach him how to fish and you feed them for a lifetime. Hopefully this video will not only set you on the road to become a WordPress ninja, you’ll also be in a position to help others and share your expertise. You’ll be in a position to take control of things and get to the next level. You’ll never need to ask how to do a specific thing in a specific theme or child-theme. All themes are different by looks but built on the same base of WordPress and PHP.

During this video you’ll see how I did things when I was starting out and you can provide feedback in the comments so that I can learn a thing or two from you. Since this is for those starting out with WordPress and Genesis and the child-themes I’m going to stay away from advanced and sophisticated ways of doing things. That could be a video for later.

Common Problems

  1. How do I so and so thing with this child-theme?
  2. What does this piece of code do?

There are two ways to change or modify a theme to tweak the functionality. This could mean adding, removing or just altering something.

The first way is to edit the files themselves. (You may need to create a child-theme so that your changes are not overwritten when the theme is updated). The other way is to use WordPress hooks.

What is a hook?

A hook is like an event that happens. And you can tell your code to do something specific when that even occurs. It’s like saying open the door when the doorbell rings. In this case the hook is the ringing of the doorbell and the action to take is to open the door.

There are two types of hooks:

  1. Action Hooks– These allow you to execute your custom functions when they execute.
  2. Filter Hooks– These allow you to filter certain content or variables.

 

 

7 Comments

  1. What puzzles me is why do you need to use hooks? in the example of the before comments
    echo= Hey here are the comments for this post but isn’t it easier to just write in html?
    I find it a very confusing subject

    Reply
  2. aha now I understand it better but if I use a childtheme I should be save?
    I recently purchased lander.

    Reply
    1. Adrien, Lander is a child-theme and allows awesome customization right from the settings so for much of the part you don’t need to worry about using hooks 🙂

      Reply
  3. what a relief! but I watch all 3 video’s anyway because I learn a lot.

    One question about lander if you don’t mind. A few months ago I build my first website with the sample child theme. I want to use the layout again can I accomplish that with lander too (or any other design I would like). In other words can I use and build my own style if I don’t want to use the 3 styles which are already available?

    Reply
    1. You can create absolutely any design with Lander that you want. Just go to Lander Admin > Design Selector. Type a design name under “Create a new design” and save. Then you can go to Design Settings and customize it the way you want 🙂

      Reply
  4. great I’ll start next week I’m looking forward to it!

    just watched your second video and learned things again.
    Tomorrow the 3th one! thanks for creating those video’s and looking forward to more :)!

    Reply

Comment on [Video]—A Beginner’s Guide To Using WordPress Hooks

Your email address will not be published. Required fields are marked *