Hi, When working with the Wiki (Confluence) docs, there are times when we have to point off to sub-pages within a main set of instructions, so that the main page does not get too bulky. This means that when a user clicks these links, they will be redirected to those new pages within the same tab. Instead, it will be better if such links can be opened in a new tab/page, so that the user can always have the main set of instructions at hand.
I found the following code block in [1], which needs to be added to a HTML macro, to open external links and internal links in a new page. However, the drawback when using this code block is that even the links in the table of contents open in a new window :( Will someone please be able to help by tweaking this code to stop links in the table of contents opening in a new page? Please note that I have created a set of sample pages in my wiki sandbox in [2], so that you can test the tweaked code if needed. <script> jQuery(document).ready(function() { jQuery(".wiki-content a").attr("target", "_blank"); }); </script> [1] https://confluence.atlassian.com/display/CONFKB/How+to+force+links+to+open+in+a+new+window [2] https://docs.wso2.com/display/SM100/Main+page+with+instructions Regards, Mariangela *Mariangela Hills* Senior Technical Writer - WSO2, Inc. http://wso2.com Committer and PMC member - Apache Stratos email:mariang...@wso2.com | mobile: +94 773 500185
_______________________________________________ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev