As a WordPress plugin developer, the 3 most important things I put in my code are:

  1. Translatable Text (__, _e, _n, etc)
  2. apply_filters
  3. do_action

Why are those the most important, you might ask? Freedom. They are important because they allow any user or developer to bend my plugins to their specific needs. The whole POINT of the plugin system for WordPress is to help people extend their site to be so much more than a standard blogging platform. I was looking into building a new (and free) Pushover Notification extension for a plugin tonight, when I came across something that frustrated the heck out of me.

  • Plugin Downloads: 1,717,451
  • Searching 138 files:
    • Search code for do_action: 0 found
    • Search code for apply_filters: 3 found

One of the top 20 plugins on the WordPress repository, with almost 1.75 million downloads, has but a TRACE of extensibility.

To contrast, let me give you some stats on another plugin:

  • Plugin Downloads: 99,948
  • Searching 296 files:
    • Search code for do_action: 217 found across 45 files
    • Search code for apply_filters: 280 found across 50 files
  • Add On Plugins: ~126

Because this second plugin is so extensibile, at least 126 ‘extensions’ have been created to make this plugin extend past it’s core functionality. This is all due to the inclusion of almost 500 points of integration that the developers have created.

My frustration with the first plugin is that, because the developers simply didn’t think it was necessary to use actions and filters, the plugin can never become more than the sum of it’s own parts. This saddens me as a developer, but more as a WordPress user and community member.

If you aren’t including actions and filters in your plugins because you aren’t quite sure where to get started, that’s ok, we’ve all been at that point. Start by reading up on the codex pages for both:

do_action
apply_filters

Tom McFarlin also wrote up a great Beginners Guide to WordPress Actions and Filters

Now go out and start applying filters and doing actions!

Posted by Chris Klosowski

Chris Klosowski is the Director of Technology at Sandhills Development, LLC, creators of fine WordPress plugins, and ecommerce solutions.

27 Comments

  1. This paragraph will help the internet users for creating new weblog or even a blog from start to end.

    Reply

  2. Very good post. I am dealing with some of these issues as well..

    Reply

  3. I feel that is among the most vital info for me.
    And i am happy studying your article. But wanna remark on few common issues, The site taste is wonderful, the articles is truly great :
    D. Good job, cheers

    Feel free to visit my blog … ntc33 trusted company (Marcia)

    Reply

  4. It’s ɑn remarkaƄle piece of writing іn fagor of all the
    onlіne viewers; they will taake benefit from it
    I am sure.

    Reply

  5. I like assembling utile info, this post has got me even more info!

    my webpage – Body Core Keto Review

    Reply

  6. Hello to every body, it’s my first visit of this web site; this website contains awesome and genuinely good data
    in favor of visitors.

    Check out my homepage; live22 casino download

    Reply

  7. Thank you for sharing with us, I think this website truly stands out :D.

    Here is my web-site – Gorges De Soleil Cream

    Reply

  8. Some truly prime blog posts on this web site, saved to fav.

    my web site :: Essential Nutrition Male Enhancement

    Reply

  9. Saya telah berselancar online lebih dari 4 jam hari ini, namun saya tidak pernah menemukan artikel
    menarik seperti milik Anda. It is cukup berharga bagi saya.
    Menurut pendapat saya , jika semua pemilik web dan blogger membuat konten yang baik seperti yang Anda lakukan, net akan menjadi a jauh lebih
    berguna dari sebelumnya.

    my web blog … Joker388 deposit pulsa

    Reply

  10. Excellent post. I was checking constantly this blog and I’m impressed!
    Extremely helpful information specially the last part 🙂 I care for such info much.

    I was seeking this particular information for a long time.
    Thank you and best of luck.

    Feel free to surf to my website; Jolt Alpha Reviews

    Reply

  11. Quality posts is the secret to interest the visitors to pay a
    visit the website, that’s what this site is providing.

    Also visit my site http://www.meteoritegarden.com/userinfo.php?uid=2718419

    Reply

  12. Toⅾay, while I was ɑt work, my cousin stople my apple ipaԀ
    and tested to ѕee if іt can survive a
    thirty foot drop, just so she can be a youtube sensation. My apple
    ipsd is now destroyеd and she has 83 views. I know this is totally off topic but I had to share іt with someone!

    Reply

  13. continuously i used to read smaller content that as well
    clear their motive, and that is also happening with this
    post which I am reading at this time.

    Here is my homepage :: Muama Ryoko Reviews

    Reply

  14. Haᴠe you ever consixered writing an ebook or guest authorig
    on otheг websites? I have a blog based on the same topics
    you discuss and ᴡould reaply like to have you shre skme stories/information. I know
    my ѕubѕcribers wouⅼd appreciate yojr work. If you’re even renotely іnterested,
    feel free to shoot me an email.

    Reply

  15. hello!,I love your writing so much! proportion we be in contact extra
    about your article on AOL? I need a specialist on this house to unravel my problem.

    Maybe that’s you! Looking ahead to look you.

    Also visit my homepage – http://marchegabonais.com

    Reply

  16. Every weekend i used to go to see this web page,
    for the reason that i want enjoyment, as this this web site conations
    truly good funny stuff too.

    Reply

  17. Hi, Neat post. There’s a problem together with your website in web explorer, might test this…
    IE still is the market chief and a good component to other folks will pass over your great writing because of this problem.

    Also visit my web-site: Gorges De Soleil Anti Wrinkle Cream

    Reply

  18. Howdy! This is kind of off topic but I need some advice
    from an established blog. Is it tough to set up your own blog?

    I’m not very techincal but I can figure things out pretty quick.
    I’m thinking about making my own but I’m not sure where
    to begin. Do you have any ideas or suggestions?
    Thank you

    my homepage :: Gorges De Soleil Anti Wrinkle Cream

    Reply

  19. It?s hard to come by knowledgeable people about this topic, however, you sound like
    you know what you?re talking about! Thanks

    Check out my site – Jolt Alpha Pills

    Reply

  20. Hello I am so excited I found your blog, I really found you by accident, while I was browsing on Bing for something else, Regardless I am
    here now and would just like to say thanks a lot for
    a incredible post and a all round thrilling blog (I also love the theme/design),
    I don’t have time to read it all at the moment but I have book-marked it and also included your RSS feeds,
    so when I have time I will be back to read a lot more, Please do keep
    up the great work.

    Reply

  21. Thanks for another informative site. The place else may just I get that kind
    of info written in such an ideal manner? I’ve a challenge that
    I’m just now operating on, and I’ve been on the look out
    for such information.

    Also visit my web blog Slimingo Review

    Reply

  22. I was able to find good info from your articles.

    My site :: Pure Optimum Keto Reviews

    Reply

  23. It’s an remarkable paragraph designed for all the internet
    viewers; they will obtain advantage from it I am sure.

    my web site … New Flow XL Male Enhancement Reviews

    Reply

  24. Hi there to all, it’s really a pleasant for me
    to pay a quick visit this website, it contains useful Information.

    Feel free to visit my page – Herbivore Calm CBD

    Reply

  25. Write more, thats all I have to say. Literally, it
    seems as though you relied on the video to make your point.
    You clearly know what youre talking about, why throw away your intelligence on just
    posting videos to your site when you could be giving us something
    informative to read?

    My webpage Solvolt

    Reply

  26. I am genuinely grateful to the owner of this web page who has shared this great piece of writing at at
    this place.

    my web page – Alpha Extracts

    Reply

  27. It’s going to be finish of mine day, but before ending I am
    reading this wonderful post to improve my knowledge.

    Feel free to surf to my web page … Alpha Extracts

    Reply

Leave a reply

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