Revision [11911]
This is an old revision of OpenExternalInNewWindow made by NickDamoulakis on 2005-11-19 12:13:36.
Open External Links In A New Window
This simple code modification will open external links in a new window. External links are defined as any link that leaves the Wiki (even if they are on the same server).
Locate this line in wikka.php, somewhere around line 662:
return $url ? "<a class=\"ext\" href=\"$url\">$text</a>$external_link_tail" : $text;
and change it to this:
return $url ? "<a class=\"ext\" href=\"$url\" target=\"_new\">$text</a>$external_link_tail" : $text;
That's all there is to it. --JasonHuebel
- Another alternative is to use this directly within the wikka page you are working on
-
<A href="http://google.com" TARGET="_blank">Google</A>
- It will show up a normal link Google
- In this case the TARGET="_blank" bit is what does the trick.
- Assuming this is what you were originally after, it has the advantage of no code changes. NickDamoulakis
CategoryUserContributions