Skip to content

Convert your links for a different Wiki engine

Most wiki engines use one of these two formats: [[EdTheDev's Blog|http://www.edthedev.com]] or [[www.edthedev.com|EdTheDev\'s Blog]] If you’re transferring your links from one wiki to another that uses a different format, you’re in for some re-typing – unless you use this little trick.

Using a text editor that supports regular expressions, do a search and replace. (Be sure to select the ‘Regular Expression’ option.)

Tell the editor to find this: [[(.)\|(.)]] And replace it with this: [[\2|\1]]

Pressing the ‘Replace All’ button will convert all of your wiki links in the document from one format to the other. Yes, it’s that easy. - Edward

Tip: Save your document first, so that if you make a mistake you can discard it.

Tip: Make sure you enter the entries exactly as you see above. Every character counts when you’re using a regular expression.

Tip: If your text editor has a ‘Match Case’ option, select it in order to preserve your capital letters.

Tip: If you’re an old-school ‘sed’ user, the command looks like this: s[[(.)\|(.)]]/[[\2|\1]]/g