“Open all external links in a new tab” option does not work for protocol agnostic links


#1

I have just noticed that in the MusicBrainz’s community I am a member of (page source code says it’s Discourse 1.6.0.beta1.
I do have the setting “Open all external links in a new tab” set on my account (:star2:).

When I go to one of my posts where I have later added a link on, clicking its links opens a new tab but clicking those same links in the History popup (the upper‐right 1 ✎ pencil icon), they will replace current window, not open a new tab.

(:star2:) on a side‐note, it seems that I had to completely reload or logout/login for that setting to completely take effect, when I set it in the beginning.

Sorry if it has already been said, I have looked it up first with no match.


External links in history don’t follow “Open all external links in a new tab” setting
External links in quoted text don’t follow “Open all external links in a new tab” setting
(Jeff Atwood) #2

Why do you need to open those links from the history view? The purpose of that view is comparing versions not opening links.


#3

Why not, I may ask. :slight_smile:
Comparing where links lead to or used to link to is also legitimate, IMO.
I usually don’t like href=_blank but for some reason in Discourse, I need it.
When you have set such an option, suddenly loosing your current page site by going external is not only inconsistent feeling but also disappointing. You have to hit the back button to shift click that link again. :slight_smile:


(Mittineague) #4

If this is that big of a problem, I guess the best solution would be to not show revision history or otherwise hidden content except to Moderators, or by Trust Level assuming more experienced members would know enough to right-click-open

But this is the first in two years time I’ve ever heard of it being a problem.

@jesus2099 how many members have complained to you about this?


#5

Maybe few people use that option.
I really like the edit history I would not want it go away.
But one thing I do not like at all is inconsistencies and uncertainty in the way a link will act.
Having to remember this page is opening them in new tab but that page is not… Does not feel very nice.

I guess you are not using that setting: would you be happy if all of a sudden, some link opens in a new tab? :wink:


#6

Off topic: can the topic remover PM me about why a valid bug report is being removed multiple times?
It is valid I do see this bug on multiple machines.
Discourse Meta and I don’t have the link to the first one.


(Mittineague) #7

I use it extremely often.

For comparison, not clicking links.

And the rare occasion I may want to see what’s at the other end of the URL I copy - paste or right-click-open.

As for inconsistency, it could be argued that the act of looking at revision histories is an inconsistent forum use in its own right,


#8

I mean you might not use the open in new tab option.
I prefer simple click than right click copy new tab paste, seriously.

You need to put yourself in the place of someone using the open in new tab option because otherwise you cannot feel how awkward this inconsistency is.
I use the pencil icon as much as the reply button.


(Mittineague) #9

As a matter of fact, my preference settings here and elsewhere are open in new tab.

One or two clicks, or even more, copy - paste, whatever, its no matter to me.

If you feel strongly about this, why not submit a pull request?


#10

Look, I just submit a bug report, I do not know your code.
Simple as that.

On a side not, open in new tab option still does not work for me at all here.
It too several days to work on another discourse site.
But that other bug report keep being erased, for some reason.

Thanks very much for your comprehension guys.


(Mittineague) #11

That’s because clicking links in a revision history modal is not a bug.

A bug by definition is something that is a problem with normal use, and clicking links in revision history modals is not normal use.

If on the other hand you mean links elsewhere, such as in posts, then there very well could be a bug.


External links in history don’t follow “Open all external links in a new tab” setting
(Erick Guan) #12

I have submitted the feature (pull) request. It’s not strictly align with your bug report but it aims to open some possibility for plugin authors.

https://meta.discourse.org/t/allowing-click-tracker-to-follow-optional-parameters/42168?source_topic_id=42224

Well, “open in a new tab” only works for links in the topic. I believe you can confirm that. In general, I think this option is meant to open external links as new tab in the topic. I am not sure though.


(Jeff Atwood) #13

Correct it seems @jesus2099 does not understand this. Perhaps the copy could be clarified in the preferences page.

If you want some magical switch to flip so every single link on the internet opens in a new tab, this preference is not that – it only affects links in replies or the first post.


#14

I reported 2 bugs. For the history bug, I did not know history was not part of discourse.

For the other bug. I have checked this option more than a day ago and only now it works.
It was not working for more than 24 hours, whatever my browser was, despite the checkbox checked and me logged in.
It seems this bug report was misread as a duplicate of the first bug report.
Can I now write down this second bug report without fearing it be deleted for the third time? :stuck_out_tongue:


(Sam Saffron) #15

Reproduce it consistently on try on multiple browsers AND report it clearly without complaining about it being closed in the OP and fine.


(Jeff Atwood) #16

No repro for me.

  1. Went to try.discourse.org
  2. Entered my user preferences
  3. Checked “open links in new tab”
  4. Navigated to homepage
  5. Entered “Whoa. Check out this crazy paper artwork” topic
  6. Clicked on the link in the last post titled “got linked 7 days ago”
  7. Link opened in a new tab

I agree we can improve copy here a bit to specify that we’re only talking about external links in posts, not every link in the world.


#17

My topics were not simply closed with notice. They were silently deleted. Twice.

As I think I said in those topics, but they are deleted now, I reproduced the case on two sites (MB’s discourse and meta discourse) and on two browsers for the same account each time (Opera 12 on Windows and Safari on iPad).

If the topics would not have been deleted silently I would have certainly be in a better mood here in this other topic.
It is how it feels to loose your time spent on trying to help others’ work in vain.
It would also have been easier to diagnose for you because now that, one or two days after, it eventually works, I am not going to test further for you.


#18

I’m happy for you that you did not trigger the bug (a cache bug or whatever) but it would make more sense that all external links within the current discourse site (has nothing to do with in the world) would share the current external link opening preference that you are setting in a given discourse website.
But I think I understand now that the history is not part of discourse but a third party plugin, which may explain nothing could be done about it.


(TechnoBear) #19

Are you using a mouse or keyboard? Because using keyboard activation for links doesn’t respect the “open in new tab” setting.

Reported here:

(And for some reason, the link to the MusicBrainz community in the first post of this topic does not open in a new tab, whether I activate it from keyboard or by mouse.)


#20

I was using the mouse.

Thanks very much @TechnoBear! :bow:
See ? It’s this same post that I was using to know when it will work.
Neither github nor MusicBrainz external links do work indeed from that post.

※ Unfortunately, we are discussing over a disappeared topic, it’s off‐topic in this topic here.
But I’m not the one who will create the right topic a third time.