Wrox Programmer Forums
|
Javascript General Javascript discussions.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Javascript section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old February 9th, 2006, 05:16 AM
Registered User
 
Join Date: Feb 2006
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default Use Map/image maps

Hi all, have some problem here, hope somebody can help.
I want to reload two frames at once (i have 5 frames in total) by using <area> tag. But in each <area> tag only allow one href. so how am I going to put two href at once?

Thanks in advance

 
Old February 9th, 2006, 05:54 AM
Friend of Wrox
 
Join Date: Oct 2004
Posts: 553
Thanks: 0
Thanked 1 Time in 1 Post
Send a message via MSN to vinod_yadav1919 Send a message via Yahoo to vinod_yadav1919
Default

Hii teresagoh!!
Can you explain in detail two frames in one <area> tag and your purspose of doing so??

since if you want ,on click of particular area to load two frames then -->
just make an html file with two frames that solve your purpose.

e.g.
<area shape ="rect" coords ="0,0,82,126" href ="openframe.htm"
target ="_blank" />

now in ur "openframe.htm" will contain
<frameset rows="*,*">
<frame name="frame1" src="frame1.html" height="100" width="100%" />
<frame name="frame2" src="frame2.html" height="100" width="100%" />
</frameset>

hope this will help you


Cheers :)

vinod
 
Old February 9th, 2006, 06:11 AM
Friend of Wrox
 
Join Date: Oct 2004
Posts: 553
Thanks: 0
Thanked 1 Time in 1 Post
Send a message via MSN to vinod_yadav1919 Send a message via Yahoo to vinod_yadav1919
Default

Hii teresagoh!!

Or alternatively use function to open two windows/pages/whtever u want

e.g
<script>
function OpenTwo()
{
window.open("exp1.html")
window.open("exp2.html")
//here you can put ur code
}
</script>

<img src ="planets.gif" width="145" height="126" usemap ="#planetmap" />

<map id ="planetmap" name="planetmap">
  <area shape ="circle" coords ="124,58,8" href ="javascript:OpenTwo()"/>
</map>


Hope this will help you

Cheers :)

vinod
 
Old February 10th, 2006, 05:27 AM
Registered User
 
Join Date: Feb 2006
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi, vinod, Thanks for ur reply. Is helpful, but it doesnt work in my code..

Is like that, I actually have 4 frames in a page. Leftframe, rightTopFrame, rightMidFrame and rightBottomFrame. the leftframe will display the raster map as well as the rightMidFrame. But the raster map display on these two frames are different. the rest of the frame will just display data. there is a label bar next to the raster map in the rightMidFrame. When clicking on the label bar, it will reload the both leftframe and rightMidFrame accordingly. I am using the <area>tag or Coordination for the label bar.

At the moment what i did is that, when clicking at the label bar, i refresh the whole page. That means i href it to a new page where i rewrite all the frame again. Actually this should be working, but the problem is that, after I reload the whole page, error that should not be happen showing like error '80020009'. Before i reload the page, this error doesn't exit. the worst still is the the raster map that actually show before load to the wrong location.

That is why I am thinking of is there any other way to do this and yet this project is quite urgent, i only have 2 days left to do it. may be is there any way to allow to change the 2 frames at the same time without disturbing other frame by using the <area> tag?

Thanks

 
Old February 11th, 2006, 03:54 AM
Friend of Wrox
 
Join Date: Oct 2004
Posts: 553
Thanks: 0
Thanked 1 Time in 1 Post
Send a message via MSN to vinod_yadav1919 Send a message via Yahoo to vinod_yadav1919
Default

Hii teresagoh !!

Again , since you want to reload only the particular frames not the whole page??
so <script>
function OpenTwo()
{
window.parent.LeftframeName.reload();
window.parent.rightMidFrameName.reload();
//or window.parent.Leftframe.src="myfile.html";
//here you can put ur code
}
</script>
Offcourse it will work,and i m 100% sure,solution to this question is possible
Hope this will help you.

Cheers :)

vinod





Similar Threads
Thread Thread Starter Forum Replies Last Post
Curious image map issue... can you help? BananaJim Javascript 2 November 29th, 2006 03:10 PM
Image Map Coords interrupt Javascript How-To 1 March 8th, 2005 09:59 AM
Image Map? sporkman43 VB.NET 2002/2003 Basics 2 July 1st, 2004 10:59 AM
image maps NeilS21 VB How-To 0 June 29th, 2004 07:35 PM
How do you represent thumbnails and image maps? mountainbiker XSLT 0 June 17th, 2004 07:22 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.