Bradycardia & Cardiac Arrest for WordPress 3.6

Bradycardia is the resting heart rate of under 60 beats per minute….

WordPress HeartbeatA new feature in WordPress 3.6 is an upgrade to the autosave functionality that’s been around for years. It’s called “Heartbeat” and it makes sure you have valid authentication credentials, aren’t working on the same post as other people, and more. The problem is that (as it is) it slows web pages down to a grinding halt.

Read the active discussion on about this feature – a lot of people are upset about the CPU load it adds.

Note: I don’t recommend doing these changes on every Admin page. Use sparingly.

Slow Down WordPress 3.6’s Racing Heartbeat

Here’s how to slow down the heartbeat from once every 15 seconds (the default) to once every minute (the max allowed by WordPress): Continue reading “Bradycardia & Cardiac Arrest for WordPress 3.6”

Generate a Link to Activate a Plugin in WordPress

Here’s another specialized plugin development tip!

If you want to create a link to activate a plugin, you need to know the path of the plugin file. Let’s use Akismet for this example.

$path = 'akismet/akismet.php';
$link = wp_nonce_url(admin_url('plugins.php?action=activate&plugin='.$path), 'activate-plugin_'.$path);

The `$link` URL will be something like

Recent Projects & Lessons Learned

There’s been a lull here on the website. That doesn’t mean I’ve been standing still. What have I been up to?

I’m going to tell you a bit about these projects and something I’ve learned from each of them. Continue reading “Recent Projects & Lessons Learned”

Passing parameters from PHP to Javascripts in plugins » Otto on WordPress

Much cleaner. One static and unchanging JS file to cache. Parameters get put into your HTML itself as a one-liner. You can deal with the parameters using a normal PHP array before passing them over. No need to screw around with generating Javascript from PHP or looking for wp-load or even messing with tricky actions.

via Passing parameters from PHP to Javascripts in plugins » Otto on WordPress.