Re: [PHP] redirecting output for a spawned child process..

2009-02-23 Thread Alpár Török
You can use a PHP workarround. Install a custom ob_handler, that has a static file descriptor, and writes all output to the file. In order to also see everything, you need to also activate implicit flush. i know that there would be lots of elegant ways to do this on linux in C, but AFAIK php

[PHP] redirecting output for a spawned child process..

2009-02-21 Thread bruce
hi... got a situation where i have a parent app that spawns children. trying to figure out how to get the output of the spawned/forked children to be written to an external file... can't seem to find any examples of how to accomplish this... do i have to insert something within the child php app

Re: [PHP] redirecting output for a spawned child process..

2009-02-21 Thread Per Jessen
bruce wrote: hi... got a situation where i have a parent app that spawns children. trying to figure out how to get the output of the spawned/forked children to be written to an external file... Normally I would use freopen() on stdout and stderr, but that's not available in PHP :-( can't

Re: [PHP] Redirecting from unreachable page on website

2009-01-22 Thread Richard Heyes
... Really, for URLs that don't exist you should be showing a 404, This way the user doesn't falsely believe that the URL is a valid one and keep using it. By using the ErrorDocument directive like Per suggested, you can customise it to be distinct helpful, like this:

Re: [PHP] Redirecting from unreachable page on website

2009-01-22 Thread Per Jessen
Richard Heyes wrote: ... Really, for URLs that don't exist you should be showing a 404, This way the user doesn't falsely believe that the URL is a valid one and keep using it. By using the ErrorDocument directive like Per suggested, you can customise it to be distinct helpful Apache also

Re: [PHP] Redirecting from unreachable page on website

2009-01-22 Thread Morris
What if the file exists, but it's kinda file to update database, like // get request $_REQUEST // execute sql statement to update database // redirect to the other page, showing results? in this case 404 approach does not mean to do correctly, so what else is suggested? 2009/1/22 Per Jessen

Re: [PHP] Redirecting from unreachable page on website

2009-01-22 Thread Richard Heyes
What if the file exists, but it's kinda file to update database, like GET requests shouldn't really modify data. -- Richard Heyes HTML5 Graphing for Firefox, Chrome, Opera and Safari: http://www.rgraph.org (Updated January 17th) -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] Redirecting from unreachable page on website

2009-01-22 Thread Per Jessen
Morris wrote: What if the file exists, but it's kinda file to update database, like // get request $_REQUEST // execute sql statement to update database // redirect to the other page, showing results? in this case 404 approach does not mean to do correctly, so what else is suggested? I

Re: [PHP] Redirecting from unreachable page on website

2009-01-22 Thread Jochem Maas
Richard Heyes schreef: ... Really, for URLs that don't exist you should be showing a 404, This way the user doesn't falsely believe that the URL is a valid one and keep using it. if the invalid URL (which outputs a 404 header) then automatically redirects to another URL then I think it's

[PHP] Redirecting from unreachable page on website

2009-01-21 Thread Dušan Novaković
Hi, Is there some elegant solution how to redirect if someone try to open some non existing page (e.g www.domain.com/nonexistingpage.php) to main page www.domain.com on website? thnx, Dusan -- made by Dusan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] Redirecting from unreachable page on website

2009-01-21 Thread Kyle Terry
On Wed, Jan 21, 2009 at 10:12 AM, Dušan Novaković ndu...@gmail.com wrote: Hi, Is there some elegant solution how to redirect if someone try to open some non existing page (e.g www.domain.com/nonexistingpage.php) to main page www.domain.com on website? thnx, Dusan -- made by Dusan --

Re: [PHP] Redirecting from unreachable page on website

2009-01-21 Thread Kyle Terry
2009/1/21 Kyle Terry k...@kyleterry.com: On Wed, Jan 21, 2009 at 10:12 AM, Dušan Novaković ndu...@gmail.com wrote: Hi, Is there some elegant solution how to redirect if someone try to open some non existing page (e.g www.domain.com/nonexistingpage.php) to main page www.domain.com on website?

Re: [PHP] Redirecting from unreachable page on website

2009-01-21 Thread Dušan Novaković
apache :-) 2009/1/21 Kyle Terry k...@kyleterry.com: 2009/1/21 Kyle Terry k...@kyleterry.com: On Wed, Jan 21, 2009 at 10:12 AM, Dušan Novaković ndu...@gmail.com wrote: Hi, Is there some elegant solution how to redirect if someone try to open some non existing page (e.g

Re: [PHP] Redirecting from unreachable page on website

2009-01-21 Thread Kyle Terry
On Wed, Jan 21, 2009 at 10:40 AM, Dušan Novaković ndu...@gmail.com wrote: apache :-) 2009/1/21 Kyle Terry k...@kyleterry.com: 2009/1/21 Kyle Terry k...@kyleterry.com: On Wed, Jan 21, 2009 at 10:12 AM, Dušan Novaković ndu...@gmail.com wrote: Hi, Is there some elegant solution how to

Re: [PHP] Redirecting from unreachable page on website

2009-01-21 Thread Per Jessen
Dušan Novaković wrote: Hi, Is there some elegant solution how to redirect if someone try to open some non existing page (e.g www.domain.com/nonexistingpage.php) to main page www.domain.com on website? See Apache ErrorDocument directive. /Per Jessen, Zürich -- PHP General Mailing List

Re: [PHP] Redirecting from unreachable page on website

2009-01-21 Thread Jochem Maas
Per Jessen schreef: Dušan Novaković wrote: Hi, Is there some elegant solution how to redirect if someone try to open some non existing page (e.g www.domain.com/nonexistingpage.php) to main page www.domain.com on website? See Apache ErrorDocument directive. ai, ErrorDocument 404

Re: [PHP] Redirecting STDERR to a file?

2008-02-04 Thread Daniel Brown
On Feb 3, 2008 10:08 PM, Richard Lynch [EMAIL PROTECTED] wrote: On Fri, February 1, 2008 10:58 pm, js wrote: Hi, I was trying to write a script in PHP that takes a program name as an argument and invoke it as a daemon. PHP provides fork(pcntl_fork), setsid(posix_setsid) and umask,

Re: [PHP] Redirecting STDERR to a file?

2008-02-03 Thread Richard Lynch
On Fri, February 1, 2008 10:58 pm, js wrote: Hi, I was trying to write a script in PHP that takes a program name as an argument and invoke it as a daemon. PHP provides fork(pcntl_fork), setsid(posix_setsid) and umask, so it was easy. However, I couldn't find a way to redirect STDERR a

Re: [PHP] Redirecting STDERR to a file?

2008-02-02 Thread Per Jessen
js wrote: I was trying to write a script in PHP that takes a program name as an argument and invoke it as a daemon. PHP provides fork(pcntl_fork), setsid(posix_setsid) and umask, so it was easy. However, I couldn't find a way to redirect STDERR a file. I like to have the daemon write its

Re: [PHP] Redirecting STDERR to a file?

2008-02-02 Thread js
nohup would work in some ways, but that's not a real daemon because the process will have tty, in a session and has a process group. I like to have a real daemon. On Feb 2, 2008 5:25 PM, Per Jessen [EMAIL PROTECTED] wrote: js wrote: I was trying to write a script in PHP that takes a program

Re: [PHP] Redirecting STDERR to a file?

2008-02-02 Thread Per Jessen
js wrote: nohup would work in some ways, but that's not a real daemon because the process will have tty, in a session and has a process group. I like to have a real daemon. Well, it depends on what you're after. Are you solving a problem or are you doing an exercise because you can? If

Re: [PHP] Redirecting STDERR to a file?

2008-02-02 Thread js
Hi Per, nohup would work in some ways, but that's not a real daemon because the process will have tty, in a session and has a process group. I like to have a real daemon. Well, it depends on what you're after. Are you solving a problem or are you doing an exercise because you can? Not

Re: [PHP] Redirecting STDERR to a file?

2008-02-02 Thread Per Jessen
js wrote: C would be the last resort. I suppose it would be easily done in Perl, but most of my colleagues prefer PHP. I love to make taking over the code easy, so PHP is more preferable to me. That makes perfect sense, but sometimes PHP is not the best/right answer. What I think you need

Re: [PHP] Redirecting STDERR to a file?

2008-02-02 Thread js
C would be the last resort. I suppose it would be easily done in Perl, but most of my colleagues prefer PHP. I love to make taking over the code easy, so PHP is more preferable to me. That makes perfect sense, but sometimes PHP is not the best/right answer. What I think you need to do

Re: [PHP] Redirecting STDERR to a file?

2008-02-02 Thread Richard Heyes
C would be the last resort. I suppose it would be easily done in Perl, but most of my colleagues prefer PHP. I love to make taking over the code easy, so PHP is more preferable to me. That makes perfect sense, but sometimes PHP is not the best/right answer. What I think you need to do is:

[PHP] Redirecting STDERR to a file?

2008-02-01 Thread js
Hi, I was trying to write a script in PHP that takes a program name as an argument and invoke it as a daemon. PHP provides fork(pcntl_fork), setsid(posix_setsid) and umask, so it was easy. However, I couldn't find a way to redirect STDERR a file. I like to have the daemon write its log to its

[PHP] Re: [BULK] [PHP] Redirecting to a parent page

2007-06-13 Thread clive
Yamil Ortega wrote: Lets say that I have the next structure on my web directory /file1.php /procces/file2.php /file3.php http://localhost/apache2/file1.php try this: header( refresh:'3'; url=./apache2/file3.php); Regards, Clive. -- PHP General Mailing List (http://www.php.net/) To

RE: [PHP] Re: [BULK] [PHP] Redirecting to a parent page

2007-06-13 Thread Yamil Ortega
List Asunto: [PHP] Re: [BULK] [PHP] Redirecting to a parent page Yamil Ortega wrote: Lets say that I have the next structure on my web directory /file1.php /procces/file2.php /file3.php http://localhost/apache2/file1.php try this: header( refresh:'3'; url=./apache2/file3.php

Re: [PHP] Re: [BULK] [PHP] Redirecting to a parent page

2007-06-13 Thread Darren Whitlen
will only then have to change it in one place. Darren Thanks in advance Yamil -Mensaje original- De: clive [mailto:[EMAIL PROTECTED] Enviado el: Miércoles, 13 de Junio de 2007 05:37 a.m. Para: PHP General List Asunto: [PHP] Re: [BULK] [PHP] Redirecting to a parent page Yamil Ortega wrote

Re: [PHP] Redirecting to a parent page

2007-06-13 Thread Richard Lynch
On Wed, June 13, 2007 11:12 pm, Yamil Ortega wrote: Lets say that I have the next structure on my web directory /file1.php /procces/file2.php /file3.php So, when I see the file1.php on the browser I see the page in this route http://localhost/apache2/file1.php I have a button that

[PHP] Re: [BULK] RE: [PHP] Re: [BULK] [PHP] Redirecting to a parent page

2007-06-13 Thread clive
Yamil Ortega wrote: Ok, but what happens if I change server and there is no more apache2 directory? Do I have to change all the headers in my 37 web pages? do this: // in a config file, or header file $sitename = http:/localhost/apache2/; eader file // whereever it is needed

[PHP] Redirecting (after output has started)

2007-04-25 Thread Don Don
Hi all, whats the best way to perform a redirect after out put has started ? using header:location will not work unless theres been no output. I usuall use the method below, however am concerned for browsers that do not support javascript. $location = 'index.php'; echo script

Re: [PHP] Redirecting (after output has started)

2007-04-25 Thread Philip Thompson
On Apr 25, 2007, at 8:25 AM, Don Don wrote: Hi all, whats the best way to perform a redirect after out put has started ? using header:location will not work unless theres been no output. I usuall use the method below, however am concerned for browsers that do not support

Re: [PHP] Redirecting (after output has started)

2007-04-25 Thread tedd
At 6:25 AM -0700 4/25/07, Don Don wrote: Hi all, whats the best way to perform a redirect after out put has started ? using header:location will not work unless theres been no output. I usuall use the method below, however am concerned for browsers that do not support javascript.

Re: [PHP] Redirecting (after output has started)

2007-04-25 Thread Richard Lynch
On Wed, April 25, 2007 8:25 am, Don Don wrote: Hi all, whats the best way to perform a redirect after out put has started ? using header:location will not work unless theres been no output. The BEST way is to re-structure your code logically, with the heavy lifting calculations done

Re: [PHP] Redirecting in a PHP script

2007-03-15 Thread clive
Larry Bradley wrote: I need to goto different PHP pages in my web site depending on what happens within some PHP code. For example, if the user is not logged in when he goes to a page, I want to send him to a LOGIN page. I've have everything working fine, using the following Javascript

Re: [PHP] Redirecting in a PHP script

2007-03-15 Thread tedd
At 11:28 PM -0500 3/14/07, Richard Lynch wrote: On Tue, March 13, 2007 11:54 pm, Chris Shiflett wrote: Tijnema wrote: Did you guys ever noted that little arrow down just right of the back button, where you can go back 2 steps at once, so you don't have to click very fast? I think we

Re: [PHP] Redirecting in a PHP script

2007-03-15 Thread Satyam
- Original Message - From: tedd [EMAIL PROTECTED] At 11:28 PM -0500 3/14/07, Richard Lynch wrote: On Tue, March 13, 2007 11:54 pm, Chris Shiflett wrote: Tijnema wrote: Did you guys ever noted that little arrow down just right of the back button, where you can go back 2 steps at

Re: [PHP] Redirecting in a PHP script

2007-03-14 Thread Tijnema !
On 3/14/07, Chris Shiflett [EMAIL PROTECTED] wrote: Tijnema wrote: Did you guys ever noted that little arrow down just right of the back button, where you can go back 2 steps at once, so you don't have to click very fast? I think we both remember browsing before that feature was invented.

Re: [PHP] Redirecting in a PHP script

2007-03-14 Thread Ben Ramsey
On 3/13/07 4:50 PM, Tijnema ! wrote: Did you guys ever noted that little arrow down just right of the back button, where you can go back 2 steps at once, so you don't have to click very fast?? Browsers have buttons in them? Next thing, you'll be telling me I can see images and color in my

Re: [PHP] Redirecting in a PHP script

2007-03-14 Thread Richard Lynch
On Tue, March 13, 2007 3:41 pm, Chris Shiflett wrote: Robert Cummings wrote: I've found clicking really fast can get you back :) I, too, have successfully used this technique. :-) +1 Sometimes back button followed at just the right time by top so I get the HTML, but no JS runs. -- Some

Re: [PHP] Redirecting in a PHP script

2007-03-14 Thread Richard Lynch
On Tue, March 13, 2007 3:50 pm, Tijnema ! wrote: On 3/13/07, Chris Shiflett [EMAIL PROTECTED] wrote: Robert Cummings wrote: I've found clicking really fast can get you back :) I, too, have successfully used this technique. :-) Chris Did you guys ever noted that little arrow down just

Re: [PHP] Redirecting in a PHP script

2007-03-14 Thread Richard Lynch
On Tue, March 13, 2007 11:54 pm, Chris Shiflett wrote: Tijnema wrote: Did you guys ever noted that little arrow down just right of the back button, where you can go back 2 steps at once, so you don't have to click very fast? I think we both remember browsing before that feature was invented.

Re: [PHP] Redirecting in a PHP script

2007-03-13 Thread Eric Butera
On 3/12/07, Larry Bradley [EMAIL PROTECTED] wrote: I need to goto different PHP pages in my web site depending on what happens within some PHP code. For example, if the user is not logged in when he goes to a page, I want to send him to a LOGIN page. I've have everything working fine, using

Re: [PHP] Redirecting in a PHP script

2007-03-13 Thread Dave Goodchild
If you do want to use the header function after html has been output, you can always look at using output buffering (ob_start()).

Re: [PHP] Redirecting in a PHP script

2007-03-13 Thread Robert Cummings
On Tue, 2007-03-13 at 21:50 +0100, Tijnema ! wrote: On 3/13/07, Chris Shiflett [EMAIL PROTECTED] wrote: Robert Cummings wrote: I've found clicking really fast can get you back :) I, too, have successfully used this technique. :-) Chris Did you guys ever noted that little arrow down

Re: [PHP] Redirecting in a PHP script

2007-03-13 Thread Chris Shiflett
Tijnema wrote: Did you guys ever noted that little arrow down just right of the back button, where you can go back 2 steps at once, so you don't have to click very fast? I think we both remember browsing before that feature was invented. Chris -- Chris Shiflett http://shiflett.org/ -- PHP

[PHP] Redirecting in a PHP script

2007-03-12 Thread Larry Bradley
I need to goto different PHP pages in my web site depending on what happens within some PHP code. For example, if the user is not logged in when he goes to a page, I want to send him to a LOGIN page. I've have everything working fine, using the following Javascript code:

Re: [PHP] Redirecting in a PHP script

2007-03-12 Thread Tijnema !
On 3/12/07, Larry Bradley [EMAIL PROTECTED] wrote: I need to goto different PHP pages in my web site depending on what happens within some PHP code. For example, if the user is not logged in when he goes to a page, I want to send him to a LOGIN page. I've have everything working fine, using

Re: [PHP] Redirecting in a PHP script

2007-03-12 Thread Robert Cummings
On Mon, 2007-03-12 at 22:43 +0100, Satyam wrote: The only way to actually go back in those is to open the dropdown list for the back button and skip over one item. I've found clicking really fast can get you back :) That does not happen when using the header() PHP function. That is my

Re: [PHP] redirecting some values from one page to other in php

2005-07-22 Thread Richard Lynch
On Wed, July 20, 2005 1:04 pm, Matt Darby said: babu wrote: It will become a big mess up for me if i combine all the files as they are large files. Scenario #1: Use include/require to suck in the files, when needed. Scenario #2: Use header(Location: ) to re-direct the browser to another file.

[PHP] redirecting some values from one page to other in php

2005-07-20 Thread babu
I am using header method for redirecting to another php file.I also want to pass some variables to the redirected file. for example: file1.html where i have a dropdown menu. the user selects the options... this form has a action to file2.php file2.php--- i get the values of the form by

Re: [PHP] redirecting some values from one page to other in php

2005-07-20 Thread Mikey
babu wrote: I am using header method for redirecting to another php file.I also want to pass some variables to the redirected file. for example: file1.html where i have a dropdown menu. the user selects the options... this form has a action to file2.php file2.php--- i get the values of

Re: [PHP] redirecting some values from one page to other in php

2005-07-20 Thread babu
It will become a big mess up for me if i combine all the files as they are large files. Matt Darby [EMAIL PROTECTED] wrote: babu wrote: I am using header method for redirecting to another php file.I also want to pass some variables to the redirected file. for example: file1.html where i

Re: [PHP] redirecting some values from one page to other in php

2005-07-20 Thread Matt Darby
babu wrote: It will become a big mess up for me if i combine all the files as they are large files. Matt Darby [EMAIL PROTECTED] wrote: babu wrote: I am using header method for redirecting to another php file.I also want to pass some variables to the redirected file. for example:

Re: [PHP] redirecting some values from one page to other in php

2005-07-20 Thread babu
does session.auto_start should be set to 1 for sessions to work. Mikey [EMAIL PROTECTED] wrote:babu wrote: I am using header method for redirecting to another php file.I also want to pass some variables to the redirected file. for example: file1.html where i have a dropdown menu. the user

Re: [PHP] redirecting some values from one page to other in php

2005-07-20 Thread Matt Darby
babu wrote: does session.auto_start should be set to 1 for sessions to work. Mikey [EMAIL PROTECTED] wrote:babu wrote: I am using header method for redirecting to another php file.I also want to pass some variables to the redirected file. for example: file1.html where i have a

[PHP] redirecting to a success page

2004-11-22 Thread Judson Vaughn
Group, I have a create_login.php page, which works (it inserts data into the database), but I need for the script once executed to redirect to a success.php page. It doesn't do this and I can't figure out how to do it. I've included a portion of the script below. This was created by

Re: [PHP] redirecting to a success page

2004-11-22 Thread Randy Rinehart
, 2004 8:13 AM Subject: [PHP] redirecting to a success page Group, I have a create_login.php page, which works (it inserts data into the database), but I need for the script once executed to redirect to a success.php page. It doesn't do this and I can't figure out how to do it. I've included

RE: [PHP] redirecting to a success page

2004-11-22 Thread Jay Blanchard
[snip] I have a create_login.php page, which works (it inserts data into the database), but I need for the script once executed to redirect to a success.php page. [/snip] http://www.php.net/header header(Location: success.php); exit(); -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] redirecting to a success page

2004-11-22 Thread Robby Russell
On Mon, 2004-11-22 at 09:13 -0500, Judson Vaughn wrote: Group, I have a create_login.php page, which works (it inserts data into the database), but I need for the script once executed to redirect to a success.php page. It doesn't do this and I can't figure out how to do it. I've

Re: [PHP] redirecting to a success page

2004-11-22 Thread Richard Davey
Hello Judson, Monday, November 22, 2004, 2:13:13 PM, you wrote: JV The original script, created by Dreamweaver, gives an error that says JV header has already been sent. I tried different options to no avail. I JV realize this script is now seriously hosed but thought I would include JV it

Re[2]: [PHP] redirecting to a success page

2004-11-22 Thread Richard Davey
Hello Randy, Monday, November 22, 2004, 2:22:31 PM, you wrote: RR You can send a header to redirect like below. I think he already had that (although it wasn't in the source code posted) because he said the error was the headers already sent one. Dreamweaver has a lot to answer for :) Best

[PHP] redirecting to another page

2004-09-25 Thread AMC
Hi, What code do I use to redirect a user to a different page in php? Thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] redirecting to another page

2004-09-25 Thread Jason Davidson
eh hem,,, that is a great question to consult the manual... but as for a hint, search for header() Jason AMC [EMAIL PROTECTED] wrote: Hi, What code do I use to redirect a user to a different page in php? Thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe,

Re: [PHP] redirecting to another page

2004-09-25 Thread Chris Shiflett
--- AMC [EMAIL PROTECTED] wrote: What code do I use to redirect a user to a different page in php? There are several methods, but my favorite is to use a Location header which also changes the response status code. This method is transparent to the history mechanism, so users can still click the

[PHP] redirecting to another frame using php header function

2004-08-11 Thread bruce
hi... can anyone point me to a way to do a page redirect using the php 'Header' function to another frame. I have a page in one frame, when the user does a submit, i want to have the app do a redirect using the 'Header' function, with the subsequent page being displayed in another frame. didn't

Re: [PHP] redirecting to another frame using php header function

2004-08-11 Thread John Nichel
bruce wrote: hi... can anyone point me to a way to do a page redirect using the php 'Header' function to another frame. I have a page in one frame, when the user does a submit, i want to have the app do a redirect using the 'Header' function, with the subsequent page being displayed in another

Re: [PHP] redirecting to another frame using php header function

2004-08-11 Thread John Holmes
bruce wrote: can anyone point me to a way to do a page redirect using the php 'Header' function to another frame. No. Use Javascript. -- John Holmes php|architect - The magazine for PHP professionals - http://www.phparch.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] redirecting to another frame using php header function

2004-08-11 Thread Matthew Sims
hi... can anyone point me to a way to do a page redirect using the php 'Header' function to another frame. I have a page in one frame, when the user does a submit, i want to have the app do a redirect using the 'Header' function, with the subsequent page being displayed in another frame.

[PHP] Redirecting a user

2004-07-01 Thread Shaun
Hi, Please could someone tell me how I can redirect a user to the page they came from including any query strings attached to the URL? Many thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re[2]: [PHP] redirecting

2004-02-18 Thread adwinwijaya
Hello Ian, Wednesday, February 18, 2004, 5:42:34 PM, you wrote: IF Stick something like this in your html head/head: IF meta HTTP-EQUIV=REFRESH CONTENT=5; URL=blah.php IF Location won't work because you've already sent output to the browser. IF Ian IF On Wed, 2004-02-18 at 07:19, ajay

[PHP] redirecting

2004-02-17 Thread ajay
hi! after having trawled through many google articles, i've been told that the best way to redirect a person is using header(Location:url); the problem is, i have form that is posted to another php script. This script then processes the form and then writes up a html page and includes in that

Re: [PHP] redirecting

2004-02-17 Thread - Edwin -
On Wed, 18 Feb 2004 17:19:03 +1100 ajay [EMAIL PROTECTED] wrote: snip i want the user to have say 5s to read that page and then be redirected to another page. /snip 'Not sure if it's only me but I think I've seen this recently ;) http://marc.theaimsgroup.com/?t=10769831404r=1w=2

Re: [PHP] redirecting

2004-02-17 Thread John Nichel
ajay wrote: hi! after having trawled through many google articles, i've been told that the best way to redirect a person is using header(Location:url); the problem is, i have form that is posted to another php script. This script then processes the form and then writes up a html page and includes

Re: [PHP] redirecting

2004-02-17 Thread Ian Firla
Stick something like this in your html head/head: meta HTTP-EQUIV=REFRESH CONTENT=5; URL=blah.php Location won't work because you've already sent output to the browser. Ian On Wed, 2004-02-18 at 07:19, ajay wrote: hi! after having trawled through many google articles, i've been told that

[PHP] Redirecting and get length problems

2004-01-07 Thread Chris W
In this application I am working on, if there is a problem with the data, I use a redirect to go back to the form and send the data with an error message in a get. That way the user doesn't need to retype everything. Most errors can be caught with java script before they post the form but

Re: [PHP] Redirecting and get length problems

2004-01-07 Thread Chris Shiflett
--- Chris W [EMAIL PROTECTED] wrote: 3 of the fields in this form are to store various URL's so if they are long URL's it is easy to see how I could go over the limit of the max url length. So my question is what is the best alternative? Is there a way to redirect and use a post instead of a

Re: [PHP] Redirecting and get length problems

2004-01-07 Thread John W. Holmes
Chris W wrote: In this application I am working on, if there is a problem with the data, I use a redirect to go back to the form and send the data with an error message in a get. That way the user doesn't need to retype everything. Most errors can be caught with java script before they post

Re: [PHP] redirecting to a url..

2003-07-20 Thread Louie Miranda
yes, got it working. thanks a lot.. i did use header -- Thank you, Louie Miranda ([EMAIL PROTECTED]) - Original Message - From: Chris Shiflett [EMAIL PROTECTED] To: Louie Miranda [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Friday, July 18, 2003 11:45 PM Subject: Re: [PHP] redirecting

RE: [PHP] redirecting to a url..

2003-07-20 Thread Ow Mun Heng
, Mun Heng, Ow H/M Engineering Western Digital M'sia DID : 03-7870 5168 -Original Message- From: Chris Shiflett [mailto:[EMAIL PROTECTED] Sent: Friday, July 18, 2003 11:46 PM To: Louie Miranda; [EMAIL PROTECTED] Subject: Re: [PHP] redirecting to a url.. --- Louie Miranda [EMAIL PROTECTED

[PHP] redirecting to a url..

2003-07-18 Thread Louie Miranda
I have this form with 2 values under 1 name ColTemplate. I was hoping if i can redirect it to another url? on the ?? if templateone or templatetwo. Anyhelp would be good. -- code - $v_get_template = $_POST['ColTemplate']; if ($v_get_template === 'TemplateOne') { ?? } elseif

Re: [PHP] redirecting to a url..

2003-07-18 Thread Louie Miranda
:08 PM Subject: [PHP] redirecting to a url.. I have this form with 2 values under 1 name ColTemplate. I was hoping if i can redirect it to another url? on the ?? if templateone or templatetwo. Anyhelp would be good. -- code - $v_get_template = $_POST['ColTemplate

Re: [PHP] redirecting to a url..

2003-07-18 Thread Curt Zirzow
Louie Miranda [EMAIL PROTECTED] wrote: I have this form with 2 values under 1 name ColTemplate. I was hoping if i can redirect it to another url? on the ?? if templateone or templatetwo. header('Location: http://domain/file'); Curt -- -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] redirecting to a url..

2003-07-18 Thread Louie Miranda
thanks, this is much better. -- Thank you, Louie Miranda ([EMAIL PROTECTED]) - Original Message - From: Curt Zirzow [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, July 18, 2003 2:29 PM Subject: Re: [PHP] redirecting to a url.. Louie Miranda [EMAIL PROTECTED] wrote: I have

Re: [PHP] redirecting to a url..

2003-07-18 Thread Chris Shiflett
--- Louie Miranda [EMAIL PROTECTED] wrote: echo meta http-equiv=\REFRESH\ CONTENT=\0; URL=us/index.php\; Or you may have other more advance alternatives? You can use a protocol redirect rather than relying on HTML: header('Location: http://yoursite.org/us/index.php'); Chris = Become a

[PHP] Redirecting to index.php from index.html

2003-06-17 Thread Michael
I'm a relative newbie to PHP coming from the Zope/Python/DTML world. Does anyone know of a good way, short of a javascript, to redirect from index.html to index.php. Also, can I use PHP to test for browsers, then redirect them to the appropriate page. In DTML/Python it would be : dtml-if

RE: [PHP] Redirecting to index.php from index.html

2003-06-17 Thread Ralph
- From: Michael [mailto:[EMAIL PROTECTED] Sent: Tuesday, June 17, 2003 11:42 AM To: [EMAIL PROTECTED] Subject: [PHP] Redirecting to index.php from index.html I'm a relative newbie to PHP coming from the Zope/Python/DTML world. Does anyone know of a good way, short of a javascript, to redirect

Re: [PHP] Redirecting to index.php from index.html

2003-06-17 Thread Michael
: Tuesday, June 17, 2003 11:42 AM To: [EMAIL PROTECTED] Subject: [PHP] Redirecting to index.php from index.html I'm a relative newbie to PHP coming from the Zope/Python/DTML world. Does anyone know of a good way, short of a javascript, to redirect from index.html to index.php. Also, can I

RE: [PHP] Redirecting to index.php from index.html

2003-06-17 Thread Jay Blanchard
[snip] If I use this on index.html, it does nothing. If I use it on index.php I get: Parse error: parse error, unexpected '=' in /path/to/file_named/main.php on line 3 What am I doing wrong On Tuesday 17 June 2003 02:11 pm, Ralph wrote: ?php if(strstr = ($HTTP_USER_AGENT, Mozilla/4)){

Re: [PHP] Redirecting to index.php from index.html

2003-06-17 Thread Michael
With that I get: Parse error: parse error, unexpected T_STRING in /path/to/file_named/main.php on line 4 Michael On Tuesday 17 June 2003 02:50 pm, Jay Blanchard wrote: [snip] If I use this on index.html, it does nothing. If I use it on index.php I get: Parse error: parse error,

RE: [PHP] Redirecting to index.php from index.html

2003-06-17 Thread Ralph
] Sent: Tuesday, June 17, 2003 1:12 PM To: Jay Blanchard; Ralph; [EMAIL PROTECTED] Subject: Re: [PHP] Redirecting to index.php from index.html With that I get: Parse error: parse error, unexpected T_STRING in /path/to/file_named/main.php on line 4 Michael On Tuesday 17 June 2003 02:50 pm, Jay

Re: [PHP] Redirecting to index.php from index.html

2003-06-17 Thread David Nicholson
Hello, This is a reply to an e-mail that you wrote on Tue, 17 Jun 2003 at 22:27, lines prefixed by '' were originally written by you. Oops. Typos. Try this: if(strstr($HTTP_USER_AGENT, Mozilla/4)){ header(Location: http://www.mydomain.com/moz4_page.php;); elseif(strstr($HTTP_USER_AGENT,

Re: [PHP] Redirecting to index.php from index.html

2003-06-17 Thread Michael
Parse error: parse error, unexpected T_STRING in /path/to/file_named/main.php on line 4 Here is my actual code so you can look at it and see what I am doing something wrong. I know I must be, since I don't see how php could become so popular for site development when it appears to be so

RE: [PHP] Redirecting to index.php from index.html

2003-06-17 Thread Ralph
Well it does appear to be working because according to this error, the problem is with main.php on line 4. -Original Message- From: Michael [mailto:[EMAIL PROTECTED] Sent: Tuesday, June 17, 2003 2:27 PM To: Ralph; 'Jay Blanchard'; [EMAIL PROTECTED] Subject: Re: [PHP] Redirecting

Re: [PHP] Redirecting to index.php from index.html

2003-06-17 Thread David Otton
On Tue, 17 Jun 2003 12:41:34 -0600, you wrote: I'm a relative newbie to PHP coming from the Zope/Python/DTML world. Does anyone know of a good way, short of a javascript, to redirect from index.html to index.php. Also, can I use PHP to test for browsers, then redirect them to the

[PHP] Redirecting STDOUT to a file pointer

2003-02-28 Thread Jeff Bearer
I'm working on a shell script in php. The script has an option to write to standard output, or to a file. If the filehandle is opened I'd like to redirect standard output to the file pointer. This would allow me not to have to handle every output statement twice, once with an echo and again with

Re: [PHP] Redirecting STDOUT to a file pointer

2003-02-28 Thread Jeff Bearer
Argh, I was thinking about the problem backwards, redirect the fp to stdout is the way to do it. if(!$argv[1]) $argv[1] = php://stdout; $fp = fopen($argv[1], w); fputs($fp,blah\n); fclose($fp); On Fri, 2003-02-28 at 15:11, Jeff Bearer wrote: I'm working on a shell script in php. The script has

[PHP] Redirecting to PHP

2003-02-05 Thread Alberto Brea
Dear list, My home page is index.html, that doesn't run PHP. I also have index.php which shows the same content with PHP. Can I do to automatically redirect a visitor from index.html to index.php? TIA Alberto

Re: [PHP] Redirecting to PHP

2003-02-05 Thread John Nichel
You can do it with JavaScript or a Meta refresh, but why? If both the pages are the same, why even use the HTML one? Alberto Brea wrote: Dear list, My home page is index.html, that doesn't run PHP. I also have index.php which shows the same content with PHP. Can I do to automatically redirect a

  1   2   >