User setting for open links (General)

by Auge ⌂, Wednesday, August 10, 2022, 12:57 (567 days ago) @ holger


I just tested this new feature but I can't manage to get it work.

When (how long ago) did you tested it for the first time?

I setup my user settings to "Öffne alle Links zu anderen Websites in einem neuen Browserfenster oder -tab (abhängig von den Browsereinstellungen)"

That's also my setting in this forum.

I post a new entry:

But still a klick on this link open not a new tab or browser window. I am using Firefox and other links opened in a new tab.

For me the link opens in a new tab and when I inspect the link with the developer tools, I see the target-attribute with the value `_blank`. I'm also working with the Firefox as the browser for my personal use.

What I can imagine is a caching issue because we implemented the feature in JavaScript. The setting resides in index.php?mode=js_defaults which will be generated on the fly when requesting a page but may be taken from the cache in an outdated state. If you are able to search for the link in the developer tools of Firefox, you should see the link as follows:

<a href="https://www.heise.de/" target="_blank">https://www.heise.de/</a>

The element chain, to be opened in the developer tools, is as follows.


If you don't see the target-attribute, you can check the index.php?mode=js_defaults. To open it, you have to open the source view of the page with the context menu (right click on the page (not the developer tools!) => "Seitenquelltext anzeigen"). When you click the link to index.php?mode=js_defaults in the source view (one of the last script elements in the <head>-section) you should find the following code at the bottom of the source code.

var user_settings = new Array();
 user_settings["open_links_in_new_window"] = "EXTERNAL";

If you don't see it, reload the whole page of the entry from the server with the key combination [CTRL]+[F5] respective [STRG]+[F5] on a german keyboard.

Hint: you can reload the source view of index.php?mode=js_defaults in the same manner as the first step. After reloading the JS-source you should certainly see the code line user_settings["open_links_in_new_window"] = "EXTERNAL";. If the code line is present, you are able to open external links in a new window/tab, if JS is enabled in your browser.

Tschö, Auge

Trenne niemals Müll, denn er hat nur eine Silbe!

Complete thread:

 RSS Feed of thread