473,466 Members | 2,016 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

code to popup link in new browser window

zn
How can I cause a link on a page to open up a new browser window when the
link is clicked on? I've noticed javascript code sometimes when I try to
right-click a link and open it in another window.

Is there a way to use straight HTML to cause a link to open a new browser
window?

Thanks.
Jul 23 '05 #1
13 5752
In article <Xn*******************************@216.196.97.131> , zn
(zn@zn122.edu.invalid) dropped a +5 bundle of words...
How can I cause a link on a page to open up a new browser window when the
link is clicked on? I've noticed javascript code sometimes when I try to
right-click a link and open it in another window.

Is there a way to use straight HTML to cause a link to open a new browser
window?


target=_blank

--
Starshine Moonbeam
mhm31x9 Smeeter#29 WSD#30
sTaRShInE_mOOnBeAm aT HoTmAil dOt CoM



Jul 23 '05 #2
"zn" wrote in comp.infosystems.www.authoring.html:
How can I cause a link on a page to open up a new browser window when the
link is clicked on?


It depends on your browser, but usually it's right-click and then
select "Open in New Window".

I'm sure you don't mean to ask how to write a Web page that will open
its link in a new window, because that is evil and anti-user. (Think
back to how often you've been annoyed by windows opening up unasked,
and don't do that to your visitors.)

--
Stan Brown, Oak Road Systems, Tompkins County, New York, USA
http://OakRoadSystems.com/
HTML 4.01 spec: http://www.w3.org/TR/html401/
validator: http://validator.w3.org/
CSS 2.1 spec: http://www.w3.org/TR/CSS21/
validator: http://jigsaw.w3.org/css-validator/
Why We Won't Help You:
http://diveintomark.org/archives/200..._wont_help_you
Jul 23 '05 #3
zn
Stan Brown <th************@fastmail.fm> wrote in
news:MP************************@news.odyssey.net:
"zn" wrote in comp.infosystems.www.authoring.html:
How can I cause a link on a page to open up a new browser window when
the link is clicked on?


It depends on your browser, but usually it's right-click and then
select "Open in New Window".

I'm sure you don't mean to ask how to write a Web page that will open
its link in a new window, because that is evil and anti-user. (Think
back to how often you've been annoyed by windows opening up unasked,
and don't do that to your visitors.)


Once I read up about the command, I realized the connection with the
dreaded pop-up windows, and also that some anti-pop programs would disable
the feature, so I came to my senses.

What I wanted to do was keep the reader on one page but give them the
option to look at an associated reference page quickly without disrupting
where they were (I guess like a basic popup window). But is sounds like
it'll just cause more aggravation than cause good.
Jul 23 '05 #4
On Sun, 02 Jan 2005 21:05:18 -0600, zn <zn@zn122.edu.invalid> wrote:
How can I cause a link on a page to open up a new browser window when the
link is clicked on? I've noticed javascript code sometimes when I try to
right-click a link and open it in another window.
I hate that too. That is annoying, dumb and wrong.
Is there a way to use straight HTML to cause a link to open a new browser
window?


Yes, but you really don't need a new window.
Jul 23 '05 #5
On Sun, 02 Jan 2005 23:14:18 -0600, zn <zn@zn122.edu.invalid> wrote:
Once I read up about the command,
What "command"?
I realized the connection with the
dreaded pop-up windows, and also that some anti-pop programs would
disable
the feature, so I came to my senses.

What I wanted to do was keep the reader on one page but give them the
option to look at an associated reference page quickly without disrupting
where they were (I guess like a basic popup window). But is sounds like
it'll just cause more aggravation than cause good.


I agree. I can open new windows all I like. So can your user, if it's of
any benefit.

Jul 23 '05 #6
In message <Xn******************************@216.196.97.131 >, zn
<zn@zn122.edu.invalid> writes
Stan Brown <th************@fastmail.fm> wrote in
news:MP************************@news.odyssey.ne t:
"zn" wrote in comp.infosystems.www.authoring.html:
How can I cause a link on a page to open up a new browser window when
the link is clicked on?


It depends on your browser, but usually it's right-click and then
select "Open in New Window".

I'm sure you don't mean to ask how to write a Web page that will open
its link in a new window, because that is evil and anti-user. (Think
back to how often you've been annoyed by windows opening up unasked,
and don't do that to your visitors.)


Once I read up about the command, I realized the connection with the
dreaded pop-up windows, and also that some anti-pop programs would disable
the feature, so I came to my senses.

What I wanted to do was keep the reader on one page but give them the
option to look at an associated reference page quickly without disrupting
where they were (I guess like a basic popup window). But is sounds like
it'll just cause more aggravation than cause good.


In this case (as a reference item) I would think that a separate,
*smaller* window would be fine.

i.e. a 'pop-up' window.

Unfortunately, you will need to use some javascript for this, which
means that you'll also have to provide a means for the
javascript-challenged to open the page in the existing window --
assuming that it's an essential part of your design :-(

If you do open a page in a new window, be sure to put a short note
somewhere that you will be doing so. This is important for people who
may be listening to your site rather than looking at it.

regards.

--
Jake

Jul 23 '05 #7
zn
Neal <ne*****@yahoo.com> wrote in
news:op**************@news.individual.net:
On Sun, 02 Jan 2005 23:14:18 -0600, zn <zn@zn122.edu.invalid> wrote:
Once I read up about the command,


What "command"?


target=_blank
I realized the connection with the
dreaded pop-up windows, and also that some anti-pop programs would
disable
the feature, so I came to my senses.

What I wanted to do was keep the reader on one page but give them the
option to look at an associated reference page quickly without
disrupting where they were (I guess like a basic popup window). But
is sounds like it'll just cause more aggravation than cause good.


I agree. I can open new windows all I like. So can your user, if it's
of any benefit.


Jul 23 '05 #8

"zn" <zn@zn122.edu.invalid> wrote in message
news:Xn*******************************@216.196.97. 131...
Neal <ne*****@yahoo.com> wrote in
news:op**************@news.individual.net:
On Sun, 02 Jan 2005 23:14:18 -0600, zn <zn@zn122.edu.invalid> wrote:
Once I read up about the command,


What "command"?


target=_blank


It's not a command, it's an attribute.

Jul 23 '05 #9
Harlan Messinger <h.*********@comcast.net> wrote:
"zn" <zn@zn122.edu.invalid> wrote
> What "command"?

target=_blank

It's not a command, it's an attribute.


.... and a value.

Jul 23 '05 #10

"Neal" <ne*****@yahoo.com> wrote in message
news:op**************@news.individual.net...
Harlan Messinger <h.*********@comcast.net> wrote:
"zn" <zn@zn122.edu.invalid> wrote
> What "command"?
target=_blank

It's not a command, it's an attribute.


... and a value.


And an operator.

Jul 23 '05 #11
Harlan Messinger <h.*********@comcast.net> wrote:
"Neal" <ne*****@yahoo.com> wrote
Harlan Messinger <h.*********@comcast.net> wrote:
> "zn" <zn@zn122.edu.invalid> wrote
>> > What "command"?
>> target=_blank
> It's not a command, it's an attribute.


... and a value.


And an operator.


And a major pain in the ass.

Jul 23 '05 #12
zn wrote:
Once I read up about the command [target attribute]...


http://lachy.id.au/blogs/log/2004/12/html-tags

--
Lachlan Hunt
http://lachy.id.au/
http://GetFirefox.com/ Rediscover the Web
http://SpreadFirefox.com/ Igniting the Web
Jul 23 '05 #13
zn
Neal <ne*****@yahoo.com> wrote in news:opsj1tmio06v6656
@news.individual.net:
Harlan Messinger <h.*********@comcast.net> wrote:
"Neal" <ne*****@yahoo.com> wrote
Harlan Messinger <h.*********@comcast.net> wrote:
> "zn" <zn@zn122.edu.invalid> wrote
>> > What "command"?
>> target=_blank
> It's not a command, it's an attribute.

... and a value.


And an operator.


And a major pain in the ass.


Thanks to all ... I'm a beginner.
Jul 23 '05 #14

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Obantec Support | last post by:
Hi i leached some code and strung together a popup i need for a page with 5 help buttons. Now i could use 5 scripts and pre-load the values but i would rather get a better understanding of how...
38
by: Shaun McKinnon | last post by:
HI...Here's my problem...I have a popup window that loads when i want it to, but it's not sized properly. I've set the size, but it doesn't seem to work. I've been on 8 different websites to find...
7
by: E Michael Brandt | last post by:
I have been lurking here for some time, and now would like to ask a question of you clever coders: My JustSo PictureWindow 3 Extension for Dreamweaver has stumbled in the face of the new Opera...
68
by: Steve | last post by:
Hi There, Prob a simple answer to this (I hope) but I can't quite work it out yet... I have this in a page: <map name="Map"> <area shape="rect" coords="43,68,52,77" href="map.html"...
23
by: Markus | last post by:
Hi, i have this problem: Sometimes, i can't reproduce, if i click on an small image on the website, the popup _AND_ an other Tab in firefox open. Here are the linkcode: <div...
3
by: Bob | last post by:
I am trying to create a popup page (to act as a menu) from a parent page. When the parent page (index.jsp) calls my popup function (see below) it will properly open the correct size browser window...
3
by: EnjoyNews | last post by:
I have a popup problem. I have a script that generates a popup for image viewing. It has 2 function, and the first is that it automaticly generates the popup window to the size of the image,...
11
by: Alex.Svetos | last post by:
Hello, I'm trying to get a popup to keep focus when it is re-clicked. The script below is supposed to produce this exact behaviour, however it doesn't work, at least on firefox 1.0.7 and moz...
7
by: YK | last post by:
Hi ! I saw that in Outlook Web Access (OWA) you get small notification window when a new e-mail is received even when the browser window is minimized and it appears at the right corner of the...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.