Quick List: Things WordPress Plugins Developers Can Do to Help Their Plugins Scale

1) For heavy backend operations like generating reports, don’t generate the screen on the init hook. Schedule a cron job and generate it periodically … if the administrator needs it right away, give them a refresh button.

2) Don’t autoload options unless they are really needed on every page load. And if you do autoload the option then make sure it isn’t too big 10KB should be plenty. Keep in mind if you create your option for the first time using the update_option(); [codex] function it will be autoloaded by default. So you should instead intiate the option using add_option('myoption','myvalue', false);

3) Don’t use wp_postmeta fields for numeric calculations. WordPress strongly encourages developers to work within their custom post type API, which is good, but that doesn’t mean the Metadata API is equally good for all data types. For instance a post_type, “order”, in which the record will have fields like ‘subtotal’,’tax’,’discount’,’grand_total’, which will likely be summed and counted and multiplied etc, go ahead and use a custom table with a foreign key on post_id.

About Mike Van Winkle

Ugh. I hate writing profiles. Just read the blog dude.

Comments

  1. Ahaa, its fastidious dialogue regarding this post at
    this place at this website, I have read all that, so at this
    time me also commenting at this place.

  2. Hey there! I’ve been following your site for a while now and
    finally got the courage to go ahead and give you a shout out from Humble Texas!
    Just wanted to tell you keep up the excellent work!

  3. Everyone loves what you guys are up too. This type of clever work
    and reporting! Keep up the terrific works guys I’ve added you
    guys to my personal blogroll.

  4. Hi there, its good article concerning media print, we all understand media is a wonderful source of data.

  5. My mother is a huge music fan and introduced me to a
    huge selection of music ranging from the 1920s
    onwards, including jazz (Peggy Lee, Louis Armstrong, Benny
    Goodman, Ella Fitzgerald etc). President Bill Clinton to perform
    at his first Inaugural Ball in 1993 performing his campaign theme song “Don’t Stop. According to Nicks, Kelly portrays the young Stevie Nicks blending with the soul of Nicks’s 62 year-old self.

  6. Many possibilities can be located right now to obtain cash
    in exchange for junkers. Additionally, you’ll want to remove
    any remaining license plates on the vehicle. A badly designed and made product can quite simply cheapen your car and can make you lose pounds instead
    of saving you a bundle, as they can break easily.

  7. Јe suis clairement en accord aveс toi

Speak Your Mind

*