Go Back  HTML Forums - Free Webmaster Forums and Help Forums > TOOLS OF THE TRADE > Website Scripts & Content Management Systems
User Name:
Password:
 

Reply
Thread Tools   Display Modes
  View First Unread
 
Old 03-15-2003, 07:53 AM
  #1
Ladd
Battler (Level 3)
 
Join Date: Feb 2002
Location: Ca-na-dA
Posts: 23
iTrader: (0)
Ladd is on a distinguished road
Having a button target a new page?

Hi all, I hope this is the right forum for this. I did search for a bit first but I cant seem to find anything that answers my question.

I have a button script and when you press it, it opens the page in the same window. I want to make it open a new window if i can (target="new") But i cant get it to work. Here is the button code that I am using:

Code:
<form><input type="button"   value="   Index   " 

onclick="location.href='addy of the page i want opened'"

onMouseOver="this.style.backgroundColor='#3299CC';
 
this.style.cursor='hand';" 

onMouseOut=this.style.backgroundColor="#000000" ></form>

How can I get this to work? It just keeps opening the page in the same window no matter where I put target="new". Any ideas? Any help would be greatly appreciated. Sorry if this is something simple that I am overlooking, its been a while since I've played with this stuff.

<edited to fix widescreen, sorry, Ladd>
Ladd is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 03-15-2003, 01:42 PM
  #2
Rigrunner
Aspirant (Level 2)
 
Rigrunner's Avatar
 
Join Date: Dec 2002
Location: uk
Posts: 19
iTrader: (0)
Rigrunner is on a distinguished road
try


<form><input type="button" value=" Index "


onclick="window.open('addy of the page you want opened')"
onMouseOver="this.style.backgroundColor='#3299CC';

this.style.cursor='hand';"

onMouseOut=this.style.backgroundColor="#000000" ></form>


Hope it works for what you want
Rigrunner is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 03-15-2003, 05:23 PM
  #3
Ladd
Battler (Level 3)
 
Join Date: Feb 2002
Location: Ca-na-dA
Posts: 23
iTrader: (0)
Ladd is on a distinguished road
Killer man!!!! Thank you so much, ive been fiddling with that for a while now! Thanks!
Ladd is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 03-16-2003, 09:01 AM
  #4
Rigrunner
Aspirant (Level 2)
 
Rigrunner's Avatar
 
Join Date: Dec 2002
Location: uk
Posts: 19
iTrader: (0)
Rigrunner is on a distinguished road
hey no problem glad i could help - i know how annoying it can be when it's just one line of code wrong
Rigrunner is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Reply
KEEP TABS
SPONSORS
 
Boxedart

 
 


 
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
  
 
 
 



 
  POSTING RULES
 
 
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Thread Tools
Display Modes

Forum Jump

 

All times are GMT -5. The time now is 01:52 AM.

   

Mascot team created by Drawshop.com | Web Hosting

Powered by vBulletin® Version 3.6.7
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.

Server Monitoring by ENIACmonitor 0.01
HTMLforums.com © Big Resources, Inc. Web Design by BoxedArt.com
vRewrite 1.5 beta SEOed URLs completed by Tech Help Forum and Chalo Na.