Topic: Rev 1206: _blank

Maybe I'm mistaken, but isn't the new javascript in 1206 always on?

Meaning each and every "external" rel link would be open with a frameset DTD attribute?

Re: Rev 1206: _blank

My understanding is that any link with rel="external" or class="exthelp" will be opened in a new window. Is that what you mean?

Re: Rev 1206: _blank

Yup.

Is that something really wanted, opening any rel="external" link in a new window? That kind of behavior should be in the user's hands, not in the server ones.

Re: Rev 1206: _blank

Oh, are we rehashing this discussion again? tongue
Take a look at the help links under the quick post form. Those are opening in a new window right now. Those are what class="exthelp" links are in 1.3. We've just removed the inline Javascript.
As for rel="external", I don't think that's used anywhere in PunBB. However, it makes it possible for someone to write an extension to modify the parser that opens all external pages in a new window. That's not a new idea, there are several versions of that out now as modifications. Adding the ability to open rel="external" links in a new window to the Javascript simply reduces the amount of work someone would have to do. The code is there anyway for the help links, it makes sense to use it for both.

5

Re: Rev 1206: _blank

The way it works its not quite what I originally intended. I did intend to use rel=external where relevant and then have the bit of javascript that relates to it commented out. That way people wouldn't even have to write an extension, they could just uncomment one line in the script.

6 (edited by Jérémie 2007-12-30 19:47)

Re: Rev 1206: _blank

Smartys wrote:

Oh, are we rehashing this discussion again? tongue

Well we shouldn't tongue

Take a look at the help links under the quick post form. Those are opening in a new window right now. Those are what class="exthelp" links are in 1.3. We've just removed the inline Javascript.

Yup, I didn't talk about these.

As for rel="external", I don't think that's used anywhere in PunBB. However, it makes it possible for someone to write an extension to modify the parser that opens all external pages in a new window. That's not a new idea, there are several versions of that out now as modifications. Adding the ability to open rel="external" links in a new window to the Javascript simply reduces the amount of work someone would have to do. The code is there anyway for the help links, it makes sense to use it for both.

Agreed, an extension that add a checkbox on PunBB to let user choose if the external links should be opened in a new window would probably be a good thing (short of that, not a good thing at all).

But it doesn't seem to work that way. It seems vanilla Pun 1.3 will open any rel="external" link on a new window, all the time. This isn't good, plus rel="external" is borderline microformat (and anyway is a common practice) and it's used in many websites. And, as I was once told, PunBB is meant to have the capability of flawlessly be integrated into an existing website.

Paul wrote:

The way it works its not quite what I originally intended. I did intend to use rel=external where relevant and then have the bit of javascript that relates to it commented out. That way people wouldn't even have to write an extension, they could just uncomment one line in the script.

Yup that makes more sense smile

However, do you really want to help people who would force upon their poor users such a window behavior only with a commented out line? I mean, as a web user, whenever I go to a website and find PunBB being their forums, I'm glad: it means mostly no gloat, fast, clean valid html, well indexed posts, and so on. With this system, I'm afraid in the future I'll find myself not so happy when a significant part of those websites will try to always open external link in a new window.

See what I mean?

Hey, I'm not telling you what to do, it's just a user feedback. But in my not-so-humble-opinion ( tongue ) an extension with the checkbox system should be the extent of it, and should benefit everyone.

Re: Rev 1206: _blank

So the problem is that we're opening all links with rel="external" in a new window and that this might include links that are used elsewhere in the template? If that's the case, how about we limit the javascript to look for such links within its own container div?

"Programming is like sex: one mistake and you have to support it for the rest of your life."

Re: Rev 1206: _blank

That's the biggest issue yup, but not only.

It also means that every external link inside PunBB would be almost force opened in a new window for everyone, and that's just wrong behavior, that kind of thing should be controlled by the end user, not the software writer or the webmaster.

In my opinion:

- tagging external link (but I wander how you decide what's external and what's not... if we are on forums.punbb.org, would www.punbb.org/download/ for example be external?) is good, people could use that ground to build tools on it (and I would say, adding an "external" class with the rel attribute would be nice too).

- opening specific links as popup (like contextual help, smiley selection, things like that) is good too. But I would do it with the window.open() method, to avoid using a wrong DTD attribute, and because Firefox for example would open these popup while opening _blank in a new tab (less helpful here).

- forcing default PunBB behavior to open any external link on a new window (at least, trying to) is bad; again this should be the sole decision of the end user. And it -might- +will+ conflict with site-wide policy and existing tools on link, external links, and rel="external" links.

If you want to offer the new window capability to your users (because they are bugging you to... a classic thing), I would suggest going (vanilla, official extension, or personal extension; as you prefer) the checkbox way (add a small checkbox somewhere on the UI that says "Open external link in a new window?", unchecked by default, and use a cookie to keep that data).

Re: Rev 1206: _blank

It also means that every external link inside PunBB would be almost force opened in a new window for everyone, and that's just wrong behavior, that kind of thing should be controlled by the end user, not the software writer or the webmaster.

http://kb.mozillazine.org/Browser.link. … ir_effects

10

Re: Rev 1206: _blank

We are getting sidetracked. This was a quick fix to get rid of inline javascript from help links so we can get on with putting out a beta.

Re: Rev 1206: _blank

Hence my first question in my first post...

Sorry about the sidetrack. I just wanted to be sure I read the revision correctly, and to point it out the issues with it.

Re: Rev 1206: _blank

The reason we went with target="_blank" as opposed to window.open() is to get around the issue with broken popup stoppers (most of them).

"Programming is like sex: one mistake and you have to support it for the rest of your life."

Re: Rev 1206: _blank

I haven't tested them all, but the one I have don't block voluntary window.open(), and block most involuntary _blank one.

Re: Rev 1206: _blank

The purists thanks you smile