2009-05-31 9 views
2

Sometimes a user will click on a link on a page, and it seems that there is no reaction -- nothing is loaded. It turns out that all the links on that page is targeting a window name, such as "news_content". The user previously already clicked on a news headline, and so when the user now clicks on another news headline, that window (usually another tab nowadays) will load the news, but the original tab is still the one being shown. To the user, this seems like nothing is happening.が使用されています<a href=" ... " target="window_name"> not a good practice?

Are those websites using <a href=" ... " target="news_content"> ? Is it a good idea to use something like that, or can it be changed a little bit so that the focus will go to that tab instead of staying at the original tab?

(is it better that the browser always switch to the target tab? if so, then this problem looks like will be solved).

+8

したがって、新しいウィンドウで物を開けないでください。常にユーザーがその決定を下すようにする –

答えて

5

In my opinion the user should always be in control of whether a link opens in a new window or not - If they're anything like me with numerous tabs endless new windows links are a mess.

What you seem to be asking is why the browser stays at the original page when a tab is updated with content, its simple, it sees it as another webpage, say you had a page that had realtime updating, your browser would not switch to that as it sees you are on another page - for all it knows you could be reading an article, watching a video etc.

All it takes to realise a different tab/window has updated is a little bit of awareness. With windows they would generally open over the current content, however as tabs are in one window this is not possible an it remains closed, but updated.

EDIT: In response to the title... I believe it to be better practice than opening something brand new each time however feel it should be the users choice whether to load a single new tab or stay in the same one. Hope this helps.

+1

+1はユーザーのために常に制御されるべきである –

1

Link behaviour should generally be left to the user to control. In some situations, a case can be made for target="_blank" (especially now that Firefox, at least, has a "New pages should be opened in: A new tab" option), but setting all links to open in the same new window is just bad.

I, for example, hate waiting for pages to load, so I'll read down a page middle-clicking each link that interests me, which will queue them up in a series of new tabs. Five interesting links become five tabs, each loaded in the background while I'm reading the first article, so no waiting. If you make all five open in the same window/tab, though, then each one disappears when I call up the next and not only do I have to 'pick one, wait for it to load, read it, go back to the original article, repeat', but, if I don't notice that this is what's happening, then I'll also need to go back and make a second pass through the original page to re-find the links to the lost documents (or, more likely, just say "not worth my time" and never read them).

Forcing newly-opened tags to the front has a similar problem: I opened it in a new tab because I want it to load in the background while I continue reading the original document. Don't subvert my intention. I cleared the "When I open a new tab, switch to it immediately" checkbox for a reason.

+0

これが起こったら、左クリックしないでください。右クリックして選択すると、タブレスブラウザ19世紀にIE6に戻ってきた人たちの大部分のように)、個々のウィンドウが記事の上にポップアップするのを見るでしょう。私は推測するが、ウェブサイトの一般的な聴衆に依存する。 –

+0

申し訳ありませんが、右クリックしてコンテキストメニューを使って環境設定に似せるようにすることは、ブラウザ設定でユーザーが設定した環境設定を無視するための正当な理由ではありません。 のタグでも実際のものでもないので、左クリック以外の方法では動作しないjavascriptのnot-really-a-linksを使用するサイトのマイナーな詳細もありますhref属性の宛先。 –

1

Yes, these websites are using target. Well. I can't imagine in which set of circumstances using the target attribute may be useful. But perhaps there's one. I haven't come across it.

Look, always switching to another tab solves the problem you describe, but it creates others. The biggest one is that switching to another tab may come as a surprise. Usability is by and large about never surprising the user. By the way, I greatly enjoyed the book "Don't make me think."

2

One caveat to add to the conversation.

I only use target= when I know the content is destined to be in an iframe and I don't want the link click to stay in the small window.

For example the graphs I embed here : http://webnumbr.com/stackoverflow-questions

関連する問題