Page Menu Editor

Latest Version: 3.0
Works on: From version 2.5+
Last Update: 5th June 2017

Update Log

1.1 – I realised you couldn’t remove a label or attribute value once it had been set. This has now been rectified.
1.2 – Have now combined the two boxes into one section. It now appears at the top of the Advanced Options.
1.3 – Fixed an issue with version 1.2
1.4 – Minor fixes plus stripping out the added backslashes
1.5 – There is no 1.5 really, I just messed up the SVN update in the WP repository for version 1.4!
1.6 – Added in a migration function to allow you to migrate your settings over to the new All in one SEO pack plugin (if you use it) as it now uses the same code.
1.7 – Set the plugin priority to 1 as certain other menu plugins are getting their changes in first and preventing the plugin working.
1.8 – Some error fixes
1.9 – Couple of minor fixes to remove error messages showing for some.
1.9.1 – Fixed the insufficient priviledges error showing for some. Added in a couple of tags for the title attribute to replicate either the page title or menu label.
2.0 – Finally have managed to get this working with the link_before and link_after parameters, which means anyone with additional tags (such as <span> tags) within the link to make it easier for using images shouldn’t find their tags being stripped out now. Also tidied up the admin on the add/edit Page.
2.0.1 – Had to revert some of the code to fix an issue that 2.0 caused with menus and child menus.
2.0.2 – Fixed the code to work with the link_before and link_after tags.
2.0.3 – Minor bug fix where the link to the settings page was wrong (only showed up for All in One SEO pack users).
2.0.4 – Minor bug fix to remove some HTML comments that caused layout issues in MSIE.
2.0.5 – Upgraded to work with WP 3.3 which not longer contains title attributes by default.
2.1 – Rewritten the code to make it more efficient and flexible, added in an All in One SEO pack import option.
2.1.1 – Bug fixes on migration and errors showing.
2.1.2 – Bug fixes (thanks to Mark Anderson for the pointers)
3.0 – Code overhaul/modernisation, PHP improvements, documentation

The Plugin

The Page Menu Editor allows you to customise the menu label and title attribute of any Page link that’s being displayed with the Template Tag wp_list_pages(). Originally, by default WordPress gave the title attribute of any page link the same text as the anchor text and I felt there was no point repeating the same text, it’s a complete waste of time in my opinion. You should only use a title attribute on a link if you need to expand on the already given anchor text e.g. If the anchor text is ‘Home’ then you could have the title attribute as ‘Return to our Front Page’. Since WordPress 3.3, this has been removed and there is no title attribute by default.

This plugin allows you to have a different menu label to the page header (by default both are usually the same) and add a title attribute for any page you want to, and if you don’t then no title attribute will be set. It’s mainly been written for sites using WordPress as a CMS however can still be useful to anyone who has one or more pages on their site that are displayed using the wp_list_pages() tag.

Instructions

  1. Download the Plugin and unzip it.
  2. Upload it to your plugins directory and activate it via the Plugins section.
  3. Go into Manage – Pages and edit an existing page OR go to Write – Page. Below the content area you’ll see two new boxes – Page Menu Label and Page Link Title Attribute See Figure 1.
  4. Fill this out with the text you require and Save or Publish the page.
Figure 1: Page Link Title Attribute Form Box
Page Menu Editor Screenshot
Figure 2: Title Attribute Showing on Link Hover
Title Attribute Screenshot

It’s a pretty simple plugin and at present there are no options as I can’t really think of any to offer! Any requests please leave them in the comments below and if I can I’ll add them in. Any problems also leave them below or feel free to make any suggestions over on the repository at GitHub.

223 Responses

  1. Anon says:

    I also got an error when I tried to install it. My blog has WordPress 2.8 How do you fix that bug?

    • Sarah says:

      Without knowing your error I can’t really help. The plugin works with 2.8 (I’ve just not updated anything to state that yet) as I have it running on over 10 websites.

      I’ll need to know what error you get to help 🙂

  2. Hello Sarah,

    I have been using your plugin for quite some time and I’ve always found it useful.

    I have installed on a website however and it does not seem to work even when I have disabled all other plugins.

    Here is the page in question:

    http://ivo-multimedia.com/wordpress2/

    Any ideas on how to get it to work?

    Best regards

  3. Sergey says:

    Hello.
    This pluging isn’t working with “All in One SEO Pack” plugin. (Version 1.6.1)
    Is there any way to fix it?
    Thank you.

  4. John says:

    I’m at a loss. I’ve just completed my 3rd website using WordPress with virtually identical installations and the Page Menu Editor plugin just doesn’t work on my latest site. Any idea why this would be?

    Thanks
    John

  5. John says:

    Hi Sarah
    Forget my last post. I got it. It turns out I forgot to fill out the menu label in the All in One SEO Pack as well as the Page Menu Editor. Fantastic Plugin…many thanks.
    John

  6. Alec Tritton says:

    Hi Sarah
    Don’t appear to be able to get it to work properly on this blog – could be interaction with anotehr plugin but I am trying to have the label as “Home” and can’t get it to work.
    Happy to let you have access to admin panel if you want to look
    Regards
    Alec

  7. cannobbio says:

    Hi. I’m running WP 2.8.1 with Page menu editor 1.5,
    The latest update of All in One SEO Pack to version 1.6.3 breaks your plugin by preventing the menulabels to show up.
    I can see the custom field set up correctly but my menu labels don’t change at all.
    If I deactivate All in One SEO Pack everithing goes back to normal.
    Does someone else have the same problem?

    Thank you for your work and good luck!

    EDIT: Just figured out this new version ef All in One SEO Pack has a menu label option that overrides the one set up in Page Menu Editor.

  8. Sarah says:

    Sorry for the late reply to everyone, just moved house so have been lacking an internet connection. It looks like a recent update to the All in One SEO pack has clashed with my plugin, and the AIOS pack plugin actually deals with the menu label now anyway. Not sure if it does both.

    I’ll have to upgrade the plugin on a CMS site of mine and see what it affects and whether my plugin is needed if you have the AIOS pack plugin.

    I’ll update here once I know more 🙂

  9. Cliff says:

    FYI: I just upgraded All In One SEO Pack, version 1.6.3 in WP 2.8.1… oh wait…

    Oops, just notice the commenter ahead of me said the same thing. Please delete this if you like.

    I couldn’t find any “menu” or “label” setting though and nothing seems to help in the SEO settings. Hmm…

    And thanks for the great plugin!

  10. Jason says:

    I had the same problem after upgrading All in One SEO.

    There are no menu label settings in the SEO plugin settings page, but each page now has a menu option under the SEO section.

    So I just copied and pasted my menu label and title attribute fields into the right boxes on each page. Sorted.

    Looks like All in One SEO has the same functionality as this module now.

  11. Sarah says:

    I’ve just checked this myself further to Jason’s comment above, and I can confirm that the new All in One SEO Pack plugin now offers the exact same settings as the Page Menu Editor plugin to allow you to edit the menu label and title attribute of the link.

    Therefore if you are running the AIOSP plugin you no longer need the Page Menu Editor plugin. However, if you are not running the other plugin then mine will continue to run without a problem 🙂 As I myself do not run the AIOSP plugin on blog sites (just CMS sites), development (when required) and support of the plugin will continue 🙂

  12. David says:

    I’m actually not having success with either. Is your Blog up to the latest WordPress build? After this plugin not working, I’m trying AIOSEO and finding that when I define menu label as “BLAHBLAH” it maintains the WordPress page title.

    Anyone else having similar issues? I had both installed at the same time as well, altering the menu listing, to no avail, then removed all but the AISEO and that failed to work too.

    • Sarah says:

      Hi David, it sounds like your wp_list_pages() output it being affected by possibly your own settings or another plugin, and then the pattern matching needed will not work. If you can supply a link to your site or a copy of your page menu markup then I can check this for you.

      Running the two plugins together will no longer work, and I run versions of each on WP 2.8 sites so both work fine (apart, not together!).

  13. I just visited a clients blog today to upgrade wp to 2.8.1 and at the same time I tested disabling your plugin and using the newest version of all in one seo pack plugin instead to control the menu labels of the pages, and it worked fine.

  14. Sarah says:

    Hi Ander, yes the AIOSP now incorporates my plugin’s code. I’ve spoken to the developer, Michael, and he’s also adding a migration script to save everyone who uses both plugins the time of copying the settings from one plugin options to the other.

  15. Laurens says:

    Is that migration script embedded in the AIOSP upgrader or something that you run separately? I don’t seem to find any reference to it on the AIOSP support pages.

  16. Sarah says:

    Hi Laurens, as far as I’m aware it’s not in there yet. I may write my own this weekend if Michael doesn’t release an update, as I need it myself, so if I do I’ll post it up here for anyone who wants to use it 🙂

  17. Malcolm says:

    I found a conflict with classy wp_list_pages(http://code.dunae.ca/classy_wp_list_pages/) so I hacked the code of page-menu-editor to add id=”‘.strtolower($menulabel).'”
    on line 31 to allow me to style each menu item individually – works a treat. Great plugin otherwise – thanks.

  18. Laurens says:

    Any news on the possibility of migrating setting between this plugiin and the All-in-One SEO plug-in?

    • Sarah says:

      Hi Laurens, sorry for the delay, work has got me snowed under. I’ve just uploaded a new version of my plugin which checks for the All In One SEO Pack plugin and allows you to migrate your settings with it. Sorry for the delay on this (to you and everyone else). I had spoken to the other developer and hoped he would add the migration in himself but that doesn’t appear to be the case so I’ve added the extra code required to do this.

  19. Laurens says:

    Thanks Sarah, much appreciated.

    Now I only need to convince the author of the Fold Page List plug-in to make his plug-in compatible with the All-In-One SEO settings. It worked fine combined with your plug-in but not with the migrated settings from the All-In-One SEO plugin.

    Upgrading WordPress and all its plug-ins can be such a hassle that I often wonder why I still get lured into doing it. Everything worked fine until I had this sudden urge to upgrade to the latest and greatest.

  20. Cian says:

    Hi there, great plugin works great 99% of the time I’ve just found one problem with it.

    I want to wrap my anchor text in a span and the plugin doesn’t seem to work when I use the link_before and link_after parameters for wp_list_pages

    Maybe I’m doing something wrong as I’m pretty new to wordpress.

    Any help would be much appreciated

  21. Sarah says:

    Hi Cian, the script is written to detect a certain pattern of code to find the page ID, URL and anchor text, so if it doesn’t follow this then it won’t work. If you’ve changed the default list tags to something else then that will create a different pattern and it won’t be able to match it.

    Unfortunately it’s not a precise method of altering the page list so it just follows the default listing style which is suitable for most people. Is there any reason you cannot use the default list item tags?

  22. Cian says:

    Hi Sarah, thanks for the response.
    Basically I needed the span so I could have curved corners using the css sliding doors technique, but it looks like I’m going to have to find some kind of workaround.

    Thanks for the reply, and great work on the plugin. Really is very useful. I can’t believe wordpress doesn’t have it as some kind of built in option. Just a shame about the span 🙂

  23. Sarah says:

    I’m not sure about the CSS sliding doors technique but I know you can do curved corners with javascript or the jQuery curvy corner plugin, and don’t need any extra spans. I’ve got this on another WP site with a standard WP page list.

  24. Cian says:

    Ah right, I’ll have to look into that, the plugin especially. I’ve got it doing what I want temporarily by using this small hack

    http://cssglobe.com/post/3910/wordpress-hack-bulletproof-page-menu-labels

    but it involves editing the /wp-includes/classes.php file which isn’t exactly ideal. I’ll have to look into that plugin.
    Thanks for the help!

    btw here are the corners in question:
    http://wordpress1.data-creative.co.uk/

  1. Mon, 27 July, 2009

    […] Page Menu Editor – allows the user to specify distinct menu titles and page titles […]

Leave a Reply

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