Re: [PHP] Re-directing

2002-07-24 Thread Martin Clifford

Awesome!  Learn something new everyday!

That's why I love this list :o)

Martin Clifford
Homepage: http://www.completesource.net
Developer's Forums: http://www.completesource.net/forums/


>>> "Chris Sharkey" <[EMAIL PROTECTED]> 07/24/02 11:01AM >>>
Well you can actually,

If you start your script IMMEDIATELY (well before you output anything) with:


To: <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Thursday, July 25, 2002 12:47 AM
Subject: Re: [PHP] Re-directing


PHP redirects using the header() function, but it's not very useful if
information has already been sent to the browser.  ANY information,
including a hard return.  So if you have a login script, you would start
your session, register any variables, then redirect.



That would do the trick.  But like I said, once the parser begins to write
HTML to the browser, then you can no longer send HTTP headers.

Martin Clifford
Homepage: http://www.completesource.net 
Developer's Forums: http://www.completesource.net/forums/ 


>>> "Roberts, Mark" <[EMAIL PROTECTED]> 07/24/02 10:28AM >>>
Is there a way to redirect to a different script in PHP? I call it
redirecting, but can't find it in the documentation using that track.

I have a script...that if a certain criteria is met, I want to load a
different script. Haven't been able to figure that out yet. I have gotten
about it by conditionally executing a location.href in javascript. It works,
but would like to know how to do it in PHP.

~Thanks.

Mark Roberts
Sr. Systems Analyst
LanApps/Web Development
The Williams Information Services Corporation
918-573-1706
[EMAIL PROTECTED] 




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php 



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php 



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Re-directing

2002-07-24 Thread Chris Sharkey

Well you can actually,

If you start your script IMMEDIATELY (well before you output anything) with:


To: <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Thursday, July 25, 2002 12:47 AM
Subject: Re: [PHP] Re-directing


PHP redirects using the header() function, but it's not very useful if
information has already been sent to the browser.  ANY information,
including a hard return.  So if you have a login script, you would start
your session, register any variables, then redirect.



That would do the trick.  But like I said, once the parser begins to write
HTML to the browser, then you can no longer send HTTP headers.

Martin Clifford
Homepage: http://www.completesource.net
Developer's Forums: http://www.completesource.net/forums/


>>> "Roberts, Mark" <[EMAIL PROTECTED]> 07/24/02 10:28AM >>>
Is there a way to redirect to a different script in PHP? I call it
redirecting, but can't find it in the documentation using that track.

I have a script...that if a certain criteria is met, I want to load a
different script. Haven't been able to figure that out yet. I have gotten
about it by conditionally executing a location.href in javascript. It works,
but would like to know how to do it in PHP.

~Thanks.

Mark Roberts
Sr. Systems Analyst
LanApps/Web Development
The Williams Information Services Corporation
918-573-1706
[EMAIL PROTECTED]




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP] Re-directing

2002-07-24 Thread Martin Clifford

PHP redirects using the header() function, but it's not very useful if information has 
already been sent to the browser.  ANY information, including a hard return.  So if 
you have a login script, you would start your session, register any variables, then 
redirect.



That would do the trick.  But like I said, once the parser begins to write HTML to the 
browser, then you can no longer send HTTP headers.

Martin Clifford
Homepage: http://www.completesource.net
Developer's Forums: http://www.completesource.net/forums/


>>> "Roberts, Mark" <[EMAIL PROTECTED]> 07/24/02 10:28AM >>>
Is there a way to redirect to a different script in PHP? I call it
redirecting, but can't find it in the documentation using that track.

I have a script...that if a certain criteria is met, I want to load a
different script. Haven't been able to figure that out yet. I have gotten
about it by conditionally executing a location.href in javascript. It works,
but would like to know how to do it in PHP.

~Thanks.

Mark Roberts
Sr. Systems Analyst
LanApps/Web Development
The Williams Information Services Corporation
918-573-1706
[EMAIL PROTECTED] 




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




RE: [PHP] Re-directing

2002-07-24 Thread Balaji Ankem

Use header() function..

Header('Location: script name');

Best Regards
Balaji

-Original Message-
From: Roberts, Mark [mailto:[EMAIL PROTECTED]] 
Sent: Wednesday, July 24, 2002 7:58 PM
To: PHP Mailing list (E-mail)
Subject: [PHP] Re-directing


Is there a way to redirect to a different script in PHP? I call it
redirecting, but can't find it in the documentation using that track.

I have a script...that if a certain criteria is met, I want to load a
different script. Haven't been able to figure that out yet. I have
gotten about it by conditionally executing a location.href in
javascript. It works, but would like to know how to do it in PHP.

~Thanks.

Mark Roberts
Sr. Systems Analyst
LanApps/Web Development
The Williams Information Services Corporation
918-573-1706
[EMAIL PROTECTED]





**Disclaimer

Information contained in this E-MAIL being proprietary to Wipro Limited is 
'privileged' and 'confidential' and intended for use only by the individual
 or entity to which it is addressed. You are notified that any use, copying 
or dissemination of the information contained in the E-MAIL in any manner 
whatsoever is strictly prohibited.

***



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Re-directing

2002-07-24 Thread B i g D o g

Check under header() in the docs...


.: B i g D o g :.


- Original Message -
From: "Roberts, Mark" <[EMAIL PROTECTED]>
To: "PHP Mailing list (E-mail)" <[EMAIL PROTECTED]>
Sent: Wednesday, July 24, 2002 8:28 AM
Subject: [PHP] Re-directing


> Is there a way to redirect to a different script in PHP? I call it
> redirecting, but can't find it in the documentation using that track.
>
> I have a script...that if a certain criteria is met, I want to load a
> different script. Haven't been able to figure that out yet. I have gotten
> about it by conditionally executing a location.href in javascript. It
works,
> but would like to know how to do it in PHP.
>
> ~Thanks.
>
> Mark Roberts
> Sr. Systems Analyst
> LanApps/Web Development
> The Williams Information Services Corporation
> 918-573-1706
> [EMAIL PROTECTED]
>
>
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




RE: [PHP] Re-directing

2001-05-17 Thread scott [gts]

ohhh...
i thought he wanted to know how to do a
simple redirect... not how to make 
'start.php' the index...

i agree it's an odd request. why not just
name it 'index.php', or specify 'start.php'
with apache?


> -Original Message-
> From: B. van Ouwerkerk [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, May 16, 2001 4:58 PM
> To: scott [gts]
> Subject: RE: [PHP] Re-directing
> 
> 
> At 14:56 16-5-01 -0400, you wrote:
> >if you need to redirect a page, why not juse use
> >header("Location: ./newurl.php");  ??
> >
> >or, as was suggested, use the apache directive
> >to do it for you if you have access to the
> >config files... :)
> 
> Nope. .htaccess can contain almost any directive which is found in the 
> httpd.conf file. It will even work with most ISP's :-)
> 
> Meta refresh is a good idea too.. But I would consider javascript one of 
> the worst things possible. In my experience it's buggy and you need the 
> visitor to be so kind to enable javascript..
> 
> I wonder why the person who asked the question in the first place just 
> doesn't want to call his start.php (or whatever de name is) index.php .. oh 
> well probably a M$ lover.
> 
> Bye,
> 
> 
> B.
> 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Re-directing

2001-05-16 Thread B. van Ouwerkerk


>
>If you're hosting on a apache box you could have something like
>
>DirectoryIndex start.php

Forgot to mention: You can add this to .htaccess

Bye,


B.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Re-directing

2001-05-16 Thread B. van Ouwerkerk


>I use a little bit of javascript ...
>
> 
> location = "newURL.php";
> 
>
>inside the  tags.

ouch. Say I've got javescript disabled.. what happens.. exactly.. nothing. 
I hate clientside cause I can't control it.

If you're hosting on a apache box you could have something like

DirectoryIndex start.php

Should run fine.

Have fun.


B.


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Re-directing

2001-05-13 Thread Raquel Rice

Todd Cary wrote:
> 
> In my Index.html, what do I write so that the Surfer goes to my
> Start.Php?
> 
> Todd

I use a little bit of javascript ...


location = "newURL.php";


inside the  tags.

-- 
Raquel

If a man does not keep pace with his companions, perhaps it is because
he hears a different drummer.  Let him step to the music which he hears,
however measured or far away.
  --Henry David Thoreau

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Re-directing

2001-05-12 Thread Young Chi-Yeung Fan

Todd Cary wrote:

> In my Index.html, what do I write so that the Surfer goes to my
> Start.Php?

It should work to have this after your opening HTML tag in index.html:





-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]