Hi
I have small thumbnail pics on my site - I want the client to click on them
and then a new window will open without the toolbar and menu and the other
stuff - displaying just the enlarged image. Can somebody help me to do this
I just cant seem to get it right
Kind Regards
Ria 9 1672
"Ria Van Heerden" <K7*@matrix.com> ÓÏÏÂÝÉÌ/ÓÏÏÂÝÉÌÁ × ÎÏ×ÏÓÔÑÈ ÓÌÅÄÕÀÝÅÅ:
news:2g************@uni-berlin.de... Hi
I have small thumbnail pics on my site - I want the client to click on
them and then a new window will open without the toolbar and menu and the other stuff - displaying just the enlarged image. Can somebody help me to do
this I just cant seem to get it right
Kind Regards Ria
http://devedge.netscape.com/library/...w.html#1202731
here is described how to open new window
your link should be look like <a href="javascript :whatever_function()"><img
scr="your_thumbnail"></a>
Dennis Biletsky wrote:
<snip> your link should be look like <a href="javascript:whatever_function()"> [...]
The word "should" and the use of a javascript HREF (where an onckick
handler could be used, with fall-back for the javascript
disabled/incapable of linking directly to the image) should not appear
together in the same statement.
<URL: http://jibbering.com/faq/#FAQ4_24 >
Richard.
Ria Van Heerden wrote: I have small thumbnail pics on my site - I want the client to click on them and then a new window will open without the toolbar and menu and the other stuff - displaying just the enlarged image. Can somebody help me to do this I just cant seem to get it right
Given the growing popularity of pop-up blocking, do you really need a
new window. Look at:-
<URL: http://www.litotes.demon.co.uk/examp...age_popup.html >
Richard.
"Richard Cornford" <Ri*****@litotes.demon.co.uk> ÓÏÏÂÝÉÌ/ÓÏÏÂÝÉÌÁ × ÎÏ×ÏÓÔÑÈ
ÓÌÅÄÕÀÝÅÅ: news:c7*******************@news.demon.co.uk... Dennis Biletsky wrote: <snip> your link should be look like <a href="javascript:whatever_function()"> [...]
The word "should" and the use of a javascript HREF (where an onckick handler could be used, with fall-back for the javascript disabled/incapable of linking directly to the image) should not appear together in the same statement.
<URL: http://jibbering.com/faq/#FAQ4_24 >
Richard.
If javascript has been disabled, the new window couldn't be open by
javascript (like this newwin=window.open()). So in this case the only link
like this will work <a href="your_file.html" TARGET="new_name"><img
src=....... , but in this case will be open default window with menu and
tool bars. Otherwise we need new window without toolbar and menubar. So,
only javascript can help in this case.
Dennis Biletsky wrote: "Richard Cornford" <Ri*****@litotes.demon.co.uk> ÓÏÏÂÝÉÌ/ÓÏÏÂÝÉÌÁ × ÎÏ×ÏÓÔÑÈ ÓÌÅÄÕÀÝÅÅ: news:c7*******************@news.demon.co.uk...
Dennis Biletsky wrote: <snip>
your link should be look like <a href="javascript:whatever_function()"> [...]
The word "should" and the use of a javascript HREF (where an onckick handler could be used, with fall-back for the javascript disabled/incapable of linking directly to the image) should not appear together in the same statement.
<URL: http://jibbering.com/faq/#FAQ4_24 >
Richard.
If javascript has been disabled, the new window couldn't be open by javascript (like this newwin=window.open()). So in this case the only link like this will work <a href="your_file.html" TARGET="new_name"><img src=....... , but in this case will be open default window with menu and tool bars. Otherwise we need new window without toolbar and menubar. So, only javascript can help in this case.
The point Richard was trying to make, which the FAQ entry he alluded to
explains, is that href="javascript : is a BAD practice.
<a href="imageName.jpg" target="blank"
onclick="window.open(this.href,'','properties here');return false"><img
src="thumbnail.jpg" border="0".....></a>
Then, when JS is enabled, and allows it, the window can be opened as you
want it. If JS is disabled, then the viewer can at least still see/use
the page.
The problem with the entire approach is when the user is using a popup
blocker that redefines the window.open call, then the user gets no
popup, it gets no new window, they get no image. They have an utterly
broken link.
--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/
Randy Webb <hi************@aol.com> writes:
Just to be a pedant: <a href="imageName.jpg" target="blank"
I think you mean "_blank" :)
onclick="window.open(this.href,'','properties here');return
^^ why not: this.target
Otherwise I completely agree.
/L
--
Lasse Reichstein Nielsen - lr*@hotpop.com
DHTML Death Colors: <URL:http://www.infimum.dk/HTML/rasterTriangleDOM.html>
'Faith without judgement merely degrades the spirit divine.'
Lasse Reichstein Nielsen wrote: Randy Webb <hi************@aol.com> writes:
Just to be a pedant:
<a href="imageName.jpg" target="blank"
I think you mean "_blank" :)
onclick="window.open(this.href,'','properties here');return
^^ why not: this.target
Yes, it should be _blank, I can only claim my medication for my surgery
two weeks ago as my defense. And this.target as a window name has its
appeal.
--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/
"Randy Webb" <hi************@aol.com> ???????/???????? ? ???????? ?????????:
news:E9********************@comcast.com... Dennis Biletsky wrote: "Richard Cornford" <Ri*****@litotes.demon.co.uk> ÓÏÏÂÝÉÌ/ÓÏÏÂÝÉÌÁ ×
ÎÏ×ÏÓÔÑÈ ÓÌÅÄÕÀÝÅÅ: news:c7*******************@news.demon.co.uk...
Dennis Biletsky wrote: <snip>
your link should be look like <a href="javascript:whatever_function()"> [...]
The word "should" and the use of a javascript HREF (where an onckick handler could be used, with fall-back for the javascript disabled/incapable of linking directly to the image) should not appear together in the same statement.
<URL: http://jibbering.com/faq/#FAQ4_24 >
Richard.
If javascript has been disabled, the new window couldn't be open by javascript (like this newwin=window.open()). So in this case the only
link like this will work <a href="your_file.html" TARGET="new_name"><img src=....... , but in this case will be open default window with menu and tool bars. Otherwise we need new window without toolbar and menubar. So, only javascript can help in this case.
The point Richard was trying to make, which the FAQ entry he alluded to explains, is that href="javascript: is a BAD practice.
<a href="imageName.jpg" target="blank" onclick="window.open(this.href,'','properties here');return false"><img src="thumbnail.jpg" border="0".....></a>
Then, when JS is enabled, and allows it, the window can be opened as you want it. If JS is disabled, then the viewer can at least still see/use the page.
Yes, it works very well. I'm going to read FAQs again more attentively :) The problem with the entire approach is when the user is using a popup blocker that redefines the window.open call, then the user gets no popup, it gets no new window, they get no image. They have an utterly broken link.
-- Randy Chance Favors The Prepared Mind comp.lang.javascript FAQ - http://jibbering.com/faq/
Dennis Biletsky wrote:
<--snip--> Yes, it works very well. I'm going to read FAQs again more attentively :)
Pay special attention to section 2.3, paragraph6, with regards to
trimming quotes.
--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/ This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: MM |
last post by:
I am using the following code to display an image in a seperate
window.
<form>
<input type=button
onClick='window.open("image1.jpg","","width=260,height=260,resizable=0,border=0")'
value=Shhow...
|
by: D. Alvarado |
last post by:
Hello,
I am trying to open a window containing an image and I would like
the image to be flush against the window -- i.e. have no padding or
border. Can I make this happen with a single call to a...
|
by: sjp |
last post by:
I need to open new windows only for the purpose of viewing linked
images, maybe a dozen or so throughout the site. Using the
Target="blank" command is quick, easy and seems like the best way to...
|
by: Madame Blablavatsky |
last post by:
hello,
i have a few links on a page. when one clicks a link an pop up window with
an image opens.
when people click an other link i want the already availible pop up window
to close before
the...
|
by: MarkW |
last post by:
Hi,
I have a Javascript heavy application that I need to record stats from
for each click that the user makes. For all intents and purposes this
is a shopping cart application that employs a...
|
by: REB |
last post by:
Can someone help me with adding some javascript functionality to a button?
What would the proper syntax for for (please help with the javascript I am
rusty) for doing this:
...
|
by: Keshav Gadia |
last post by:
Hi,
I am an ASP.net newbie.
I am writing a user control that is made up of datagrid with one of
the columns opening a new window to display some details on click of
the set image.
I have...
|
by: Zeroed |
last post by:
Hi folks,
I've using a call to a standard piece of JavaScript that open a new window with a given URL. In my case, I'm opening an image and have specified the actual size of the image as the...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
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...
|
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,...
|
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,...
|
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...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
|
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...
| |