473,322 Members | 1,352 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

bigger image opens in new window within an existing javascript.

jp
bigger image opens in new window within an existing javascript.

I am working within a existing javascript.
see www.art4companies.nl and press kunstenaars than press any name to
see what I mean.

After clicking on the thumbnails it shows a bigger picture. I would
like to add the function, when clicked on the bigger image it will
open a new window showing the picture in a bigger size.

Thank in advance!!!

yours sincerely,

jp
Jul 23 '05 #1
1 2190
You'll need to open a new window, with the window.open() function.

<IMG SRC="smaller image.jpg" onClick="view();">

<script language="JavaScript">

function view() {
imgsrc = '... address of current image to display ...';

// for example:
// imgsrc = 'big/pic'+id1+'.jpg';

viewwin = window.open(imgsrc,'viewwin', 'width=400,height=300');
viewwin.focus(); // just in case it was already open
}
</script>

You'll need to think of a way to get the right source for an image. Also
window.open has more parameters. I suggest you look at a JavaScript
tutorial for how to open new windows.

good luck,
Vincent

jp wrote:
bigger image opens in new window within an existing javascript.

I am working within a existing javascript.
see www.art4companies.nl and press kunstenaars than press any name to
see what I mean.

After clicking on the thumbnails it shows a bigger picture. I would
like to add the function, when clicked on the bigger image it will
open a new window showing the picture in a bigger size.

Thank in advance!!!

yours sincerely,

jp


Jul 23 '05 #2

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

Similar topics

1
by: Randell D. | last post by:
Folks, I want to create a popup for thumbnail images (jpg, png, gif) and wonder if I can create a popup that opens a new window whereby the image fits the new window 100%... I know I can have my...
1
by: Markus Seibold | last post by:
Hello NG, i have a picture galerie with thumbnails. I want to add JS functionality that opens a new window with an enlarged version of the image when the user clicks on the thumbnails picture....
4
by: Amir | last post by:
Hi, I'd like to know if it's possible to pass an image name (the IMG SRC attribute) from HREF element to a function that is activated by onClick event and creates a Web page. I have this HREF...
3
by: Becky Carter Hickman-Jones | last post by:
Hi, I have a simple script that opens an image in a new window which is sized to the image. The script is as follows: <a title="xxx"...
4
by: shawn | last post by:
I have a simple script located here which loads different images when you click on some links. Everything works fine until you click on the last link which opens a popup window (zoom image). ...
1
by: Aussie Rules | last post by:
Hi, I have an image button on my page, and I want to have a popup window open up when the user clicks the imagebutton, and if possible set the window configuration(ie no tool bar, etc) like...
9
by: tshad | last post by:
This was posted before but the message got messed up (all NLs were stripped out for some reason). I have 2 labels that hold the name of different images on my .aspx page. <asp:Label ID="Logo"...
4
by: ameyas | last post by:
hi all, i am using an image which has image map and i provide the href action url. i have provided the url to open a pop up window like "javascript:window.open('www.google.com');" but on...
15
by: mistral | last post by:
I want find code for clickable thumbnails, when click on small picture, a big image will popup in new window, sized to fit picture. Same as standard javascript image previewer, but without using...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

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.