New WP Plugin – Macro Root URI

I’ve currently been working on an update for one of the companies websites. The whole site runs on WordPress, my “new” favourite CMS. However, before going live the site is running on a different location than when ready. I noticed that the import/export feature doesn’t change the URI’s inside the posts and pages. Concequently I needed something to make the “move” as quick and automatic as possible.

Inspired by Alex King’s “Shortcut Macros” plugin I decided to make something similar that would convert any root URI references with a macro, ##root to be specific. To illustrate lets say your domain is http://www.example.com. So whenever you write or update a page/post the following will happen ;

http://www.example.com/link/to/page_or_post -> ##root/link/to/page_or_post

When viewing the page the plugin will automatically reconvert #root to your blogs URI as defined by get_option(‘home’). This way your internal links will always be uptodate wherever you move your blog.

Grab the code and instructions from the download page.

One thought on “New WP Plugin – Macro Root URI