473,387 Members | 1,455 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,387 software developers and data experts.

Open photo in own window - no extra space around photo

RC
I want to display photos and when the user clicks on one the photo gets
displayed in its own window. This is what I"m currently using.

<A id="picAnchor" target="_blank" href="../Photos/somePic.jpg"><img
src='../Photos/ etc... </A>

It works great - as expected the photo shows up in a new browser window. The
thing is that I want the photo to show up in its own window - but to have
the new window's size conform to the size of the image (i.e., no extra white
space around the photo). Is there a way to do that without having to "know"
ahead of time the dimensions of the pic?

Thanks!
Nov 18 '05 #1
2 1495
load a page that references the image. with client script on the "onload()"
event resize the window.

-- bruce (sqlwork.com)

"RC" <a@b.com> wrote in message
news:%2****************@TK2MSFTNGP12.phx.gbl...
| I want to display photos and when the user clicks on one the photo gets
| displayed in its own window. This is what I"m currently using.
|
| <A id="picAnchor" target="_blank" href="../Photos/somePic.jpg"><img
| src='../Photos/ etc... </A>
|
| It works great - as expected the photo shows up in a new browser window.
The
| thing is that I want the photo to show up in its own window - but to have
| the new window's size conform to the size of the image (i.e., no extra
white
| space around the photo). Is there a way to do that without having to
"know"
| ahead of time the dimensions of the pic?
|
| Thanks!
|
|
Nov 18 '05 #2
Have a look at this:

http://www.2createawebsite.com/progr...ew-window.html

This gives you the settings that allow you to set the size of a new
browser window and load its contents.

Also take a look at:

http://www.javascript-coder.com/wind...dow-open.phtml

This will help you with turning of the toolbars and status bar if you want.

Have A Better One!

John M Deal, MCP
Necessity Software

RC wrote:
I want to display photos and when the user clicks on one the photo gets
displayed in its own window. This is what I"m currently using.

<A id="picAnchor" target="_blank" href="../Photos/somePic.jpg"><img
src='../Photos/ etc... </A>

It works great - as expected the photo shows up in a new browser window. The
thing is that I want the photo to show up in its own window - but to have
the new window's size conform to the size of the image (i.e., no extra white
space around the photo). Is there a way to do that without having to "know"
ahead of time the dimensions of the pic?

Thanks!

Nov 18 '05 #3

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

Similar topics

2
by: Raptor | last post by:
I'm a complete Javascript n00b, using a snippet I found on the web. I'll probably be buying a Javascript book. What's the authoritative on-line resource for Javascript, like php.net is for PHP? ...
2
by: Larry R Harrison Jr | last post by:
I have pull-down menus in javascript and I have the code for opening a link in a new window. But I want it to open a full-sized window. I can't figure out the syntax. What I have so far: ...
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...
29
by: wayne | last post by:
Hey there... I'm having some problems passing url parameters with an open.window command. I'm not terribly familiar with java script but here is the code below. When executed it opens the...
18
by: Roger Withnell | last post by:
I open a new window from the current window to display maps. Several maps of different sizes can be displayed. The function is given the size of the map and adjusts the window size accordingly....
3
by: Guadala Harry | last post by:
Here's the functionality I'm after: I need for a page to display a photo. When users click on other links within the page, the photo changes. I'd like to swap out the photo without doing a...
0
by: thomas | last post by:
I found John Viescas's book "Access2003 Inside and Out" most helpful especially the section on Data Access Pages, and as such I have successfully launched a Intranet Web site whereby 4 remote sites...
7
by: Toccoa | last post by:
After considerable googling - I mean searching with Google(r) - I could not find javascript on a button or <a href=... to close a window in the latest versions of IE and FireFox. There seemed...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
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
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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:
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,...

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.