Shoutbox

Open 2 IE Window's - Printable Version

-Shoutbox (https://shoutbox.menthix.net)
+-- Forum: MsgHelp Archive (/forumdisplay.php?fid=58)
+--- Forum: Skype & Technology (/forumdisplay.php?fid=9)
+---- Forum: Tech Talk (/forumdisplay.php?fid=17)
+----- Thread: Open 2 IE Window's (/showthread.php?tid=66074)

Open 2 IE Window's by MC Inferno on 09-10-2006 at 10:53 PM

<a href="http://www.mcinferno.co.uk"><img src="http://img103.imageshack.us/img103/9824/mcinfernocoukkb9.jpg" border="0" alt="www.mcinferno.co.uk" /></a>

if i enter that on most pages, it should appear as a picture that you click and takes you to www.mcinferno.co.uk

... is there anyway of making it link to two diffrent pages...? I want it so it goes to my website, but also strats downloading a file immediatly, ie. the link would be link this:

http://www.mcinferno.co.uk/force-download.php?file=Has%20Got%20Me.mp3

I hope this makes sense. Thanks

Inferno


RE: Open 2 IE Window's by Chris4 on 09-10-2006 at 10:57 PM

This might help you?


RE: Open 2 IE Window's by MC Inferno on 09-10-2006 at 11:03 PM

it didnt sorry. i dunno javascript etheir... i struggle with html


RE: Open 2 IE Window's by Zephyr on 09-10-2006 at 11:53 PM

You can play around with the code to make it how you want, but something like this should work.

code:
<a href="http://www.mcinferno.co.uk"
onClick=window.open("http://www.mcinferno.co.uk/force-download.php?file=Has%20Got%20Me.mp3")><img src="http://img103.imageshack.us/img103/9824/mcinfernocoukkb9.jpg" border="0" alt="www.mcinferno.co.uk" /></a>

Note: in IE it may asked about blocked popups.

Thats the only way i can think of opening 2 windows with one link, but you could also do want you want in a slightly different way, by linking to your page by the image, then in the source your main page, you have an onload function to link to the music.

Not sure if this is the best way to do it, someone can correct it if im wrong - i'm not great with html/javascript.

code:
<body onload=(window.open("http://www.mcinferno.co.uk/force-download.php?file=Has%20Got%20Me.mp3")>


Both methods will work, but there might be a better way which i don't know.
RE: Open 2 IE Window's by Ezra on 09-11-2006 at 12:41 AM

opening windows not triggered by clicks will be blocked by most pop-up blockers, it might just squeeze trough when opening 2 windows from 1 function ala 1 click.

Or indeed using javascripts window.open function and html's own href function.


RE: RE: Open 2 IE Window's by rav0 on 09-11-2006 at 07:57 AM

quote:
Originally posted by Ezra
opening windows not triggered by clicks will be blocked by most pop-up blockers
Yep.
quote:
Originally posted by Ezra
using javascripts window.open function and html's own href function.
href isn't a function, but anyway, using an onclick event together with a normal link will usually mean that the onclick event works and the normal link doesn't.

The way I'd approach the problem is by having the link to the page that you want to show, then have a redirecting meta tag to the mp3.

Link to user (same as you posted):
code:
<a href="http://www.mcinferno.co.uk/"><img src="http://img103.imageshack.us/img103/9824/mcinfernocoukkb9.jpg" border="0" alt="www.mcinferno.co.uk"></a>
... in second page:
code:
<head>
<meta http-equiv="Refresh" content="0;url=http://www.mcinferno.co.uk/force-download.php?file=Has%20Got%20Me.mp3">
</head>

RE: Open 2 IE Window's by davidpolitis on 09-11-2006 at 11:03 AM

I'll have something for you in a moment.

EDIT: Finished! Don't get too excited because I could not exactly do what you wanted (considering I'm only 13), what it does is puts the two webpages in one webpage. Download the attached file.


RE: Open 2 IE Window's by MC Inferno on 09-23-2006 at 08:27 PM

cheers man, apprechate that