Valuate Domain Names
DNForum - Domain Sales, Domain Forum, Domain Appraisals, Domain Registrars
HomeRegisterMembershipsGetting StartedDomain Tools Domain EbooksSEO Software Domain Resellers Advertise

Go Back   DNForum - Domain Sales, Domain Forum, Domain Appraisals, Domain Registrars > Gold Forums > Help Wanted!
Register Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old 02-29-2004, 11:08 PM   #1 (permalink)
Bob
Jedi Master
 
Bob's Avatar
 
Name: Bob
Last Online: 11-20-2009 08:54 AM
iTrader: (74)
Join Date: Apr 2002
Posts: 2,980
DNF$: 140
Location: Massachusetts
Country:


Quick PHP Question

I cannot seem to figure out how to do this or find it anywhere.

I need to open a link in a NEW browser window.

In HTML, you do it with:

a href=". . . " target="_BLANK"


In JavaScript, you do it with:

window.open(". . . ");

How do you do this in PHP?

I tried:
header('Window-target: NEW');
header('Location: http://. . . ');

But I got a "Headers already sent" error in the main document.

ACK! Help please!

-Bob
__________________
The massive purge has begun.
Bob is offline   Reply With Quote
Sponsored Ads
Old 02-29-2004, 11:14 PM   #2 (permalink)
President
 
GiantDomains's Avatar
 
Last Online: 12-13-2007 10:56 AM
iTrader: (10)
Join Date: Sep 2002
Posts: 7,062
DNF$: 325
Location: N-Y-C
Country:


Re: Quick PHP Question

Why don't you just use javascript within the php document? That's the way I do it. Not sure if there is an actual php command, but I guess there must be.
__________________
NETCHEAP - Discount Dotster Reseller - $7.99
FREE pushes from your dotster account, renew for $7.99! 1. Create a netcheap account. 2. Push from dotster to netcheap account name. 3. Renew for $7.99!
GiantDomains is offline   Reply With Quote
Old 02-29-2004, 11:20 PM   #3 (permalink)
Platinum Lifetime Member
 
Darren06's Avatar
 
Name: Darren
Last Online: 10-22-2009 06:07 PM
iTrader: (14)
Join Date: Sep 2003
Posts: 1,896
DNF$: 2,403
Location: California, US
Country:

Send a message via AIM to Darren06

Re: Quick PHP Question

Ah you cant do this in php... its an active element which means it can only be used in browser code.
__________________
Zend PHP5 Certified Engineer - If you have a great domain name let me be the one to develop it.
Darren06 is offline   Reply With Quote
Old 03-01-2004, 03:51 AM   #4 (permalink)
Exclusive Lifetime Member
 
WebCat's Avatar
 
Last Online: 04-09-2007 06:29 PM
iTrader: (0)
Join Date: Mar 2003
Posts: 1,031
DNF$: 21,741
Location: Southern California


Re: Quick PHP Question

Quote:
Originally Posted by Bob
I cannot seem to figure out how to do this or find it anywhere.

I need to open a link in a NEW browser window.
I tried:
header('Window-target: NEW');
header('Location: http://. . . ');

But I got a "Headers already sent" error in the main document.

ACK! Help please!

-Bob
Hey Bob, I'm no php guru, but I think the server is telling you you're resending http headers again, which it sounds like the server doesn't like.

I would pursue generating an html doc, with a meta equiv tag and research if there's an http header that will open a new window, similar to how the "refresh" will redirect. I definitely don't know what every one of the http headers are and do. I think there's about 60 or so, not including mime type headers.

Another possibility I'd experiment with would be to use php to generate a javascript doc that in turn executes and opens the new window.

I don't know if that helps or not. I'm probably more confused than you!

WebCat
__________________
MetallicaForum.com - DomainElf.com - Exclaims.net
DomainExpires.com - TouringSound.com - SongNet.us
SongClick.com - DedicatedTraffic.com - AmericanMovie.us
WebCat is offline   Reply With Quote
Old 03-01-2004, 03:59 AM   #5 (permalink)
Platinum Lifetime Member
 
.com.net.org's Avatar
 
Last Online: 08-25-2006 07:09 AM
iTrader: (0)
Join Date: Oct 2002
Posts: 1,976
DNF$: 1,386


Re: Quick PHP Question

Try this Bob.

Code:
<?php
echo '<a href="http://www.dnforum.com" target="_blank">www.dnforum.com</a>';
?>
__________________
Unlimited Domain Hosting - $20/mo
Dedicated Server - $99/mo
.com.net.org is offline   Reply With Quote
Old 03-01-2004, 04:17 AM   #6 (permalink)
Account Terminated
No Avatar
 
Last Online: 04-01-2004 11:50 PM
iTrader: (0)
Join Date: Feb 2004
Posts: 4
DNF$: 218


Re: Quick PHP Question

Drop me a pm if you ever have any PHP-questions or if the above didn't help you out. Am fairly experienced and don't mind helping out! (That goes for all of you)
ctrlnet is offline   Reply With Quote
Reply


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

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
PHP question Ciqala Website Development and Design Discussion 12 03-06-2003 12:21 PM
Quick .cc question com Domain Name Appraisal Discussion 9 12-22-2002 01:27 PM
Quick question - sold a domain President Gringo Domain Registration Discussion 15 12-13-2002 04:57 PM
100 DNF For Quick Answer To Trademark Question From Lawyer Gomains Domain Name Legal Issues 3 11-23-2002 12:00 PM
a nice one: mysqlphp.com Domain Name Appraisal Discussion 2 04-27-2002 05:29 PM


All times are GMT -5. The time now is 09:39 PM.
Copyright @2001-2009 DNForum.com