Wiki

Clone wiki

Wordpress Relative Menu Item Plugin / Home

Installation And Activation

The best instructions for installing and activating any plugin - including this one - can be found at Wordpress Codex - Mangaging Plugins

USAGE

When creating a custom menu item (as per Wordpress Codex - Menu Custom Links) simply prefix the relative part of your url with %ROOT%.

Let's say your site lives at www.ninjarhino.com and you want a link to www.ninjarhino.com/hairstyles. When you create a new custom link for your wordpress menu simply type in:

%ROOT%/hairstyles

This works just as well if your wordpress is installed in a subdirectory of the site. Let's say wordpress lives at www.ninjarhino.com/wordpress and you want a link to www.ninjarhino.com/wordpress/hairstyles then, exactly as before, you just type in:

%ROOT%/hairstyles

Admin Options

This plugin currently has no administration options associated with it.

Notes

You may prefix the %ROOT% with http://. It makes no difference either way. The link MUST start with either "%ROOT%" or "http://%ROOT%" though. Otherwise the search and replace will fail.

Technical Details

This plugin simply adds an action to the wp_nav_menu_items hook and does a string replace of http://%ROOT% with the value returned by the function get_bloginfo("url").

Report A Bug

This plugin has it's own https:bitbucket.org/perchten/wordpress-relative-menu-item-plugin/issues?status=new&status=open where you can report any bugs you find.

Who Am I?

This plugin was originally written by Perch Ten Design

Updated