WordPress Plugin Diversion

July 21, 2010 by Dave
Filed under: Tools 

Earlier this year I started doing some daily walking and hiking.  I would be remiss if I didn’t tie some technology into it somehow, so in my spare time I’ve been working on a WordPress plugin to track my progress.

The plugin is now showing up in the WordPress Plugin Directory for anyone who’s interested.

Walking Log WordPress Plugin

Comments

4 Comments on WordPress Plugin Diversion

  1. Ed on Wed, 28th Jul 2010 6:05 pm
  2. Okay, I give up. How do you enter anything into the log?

  3. Dave on Wed, 28th Jul 2010 6:33 pm
  4. You have to be logged in with administrator permissions to edit the log. Once you have the log showing up in a page and you’re logged in you’ll see an “edit log” button. Press that, then the “new log entry” button that appears. All of the editing happens on the WordPress page where the log appears, not in the Admin area.

  5. Jeff on Tue, 9th Nov 2010 8:41 am
  6. I had the same question as Ed… I actually sent the question to your other website. I’ve got it working now. I was logged in as another user. Is there anyway to set it up to be edited by another user? Thanks!

  7. Dave on Tue, 9th Nov 2010 11:11 am
  8. As it stands now, any user with the manage_options capability can edit the log. Generally this would only be someone with the administrator role. If you want to change this, open the .PHP code in the plugin and find this function…

    function VerifyWritePermissions()
    {
    if (!current_user_can(‘manage_options’))
    die(‘Request Failed’);
    }

    Change manage_options to something less restrictive. Here is a decent description of how current_user_can works: http://iface.wordpress.com/2006/03/06/current_user/

    I haven’t tested it, but it looks like edit_posts might be a good one to use here.

Tell me what you're thinking...