Re: [PHP] Reload page after form submit

2007-08-31 Thread brian
Afan Pasalic wrote: brian wrote: The problem that i see is here: if (isset($_POST)) This will always return TRUE. It should rather be: if (isset($_POST['name_of_your_submit_btn'])) or some other form element, at least. I don't know if this was simply because it was a rough draft of the c

Re: [PHP] Reload page after form submit

2007-08-31 Thread Afan Pasalic
brian wrote: Instruct ICC wrote: From your rough code, I'd say the OP always needs the select block (just remove the "else" keyword and keep the block) for the current info at the present page refresh/load. But I'd like clarification on how the OP thinks about it. That's close, i think

Re: [PHP] Reload page after form submit

2007-08-31 Thread brian
Instruct ICC wrote: From your rough code, I'd say the OP always needs the select block (just remove the "else" keyword and keep the block) for the current info at the present page refresh/load. But I'd like clarification on how the OP thinks about it. That's close, i think. But the select

Re: [PHP] Reload page after form submit

2007-08-30 Thread Instruct ICC
From: Martin Marques <[EMAIL PROTECTED]> Stut wrote: Wagner Garcia Campagner wrote: header('Location: index.php'); Although technically speaking that should be an absolute URL. AFAIK, they are both equivalent. Ahhh, if the OP meant, "Load a different page after doing some form processi

Re: [PHP] Reload page after form submit

2007-08-30 Thread Stut
Martin Marques wrote: Stut wrote: Wagner Garcia Campagner wrote: header('Location: index.php'); Although technically speaking that should be an absolute URL. AFAIK, they are both equivalent. Essentially yes, but personally (and for no logical reason I can think of) I always prefer hea

Re: [PHP] Reload page after form submit

2007-08-30 Thread Martin Marques
Stut wrote: Wagner Garcia Campagner wrote: header('Location: index.php'); Although technically speaking that should be an absolute URL. AFAIK, they are both equivalent. -- 21:50:04 up 2 days, 9:07, 0 users, load average: 0.92, 0.37, 0.18 --

Re: [PHP] Reload page after form submit

2007-08-30 Thread Instruct ICC
From: Afan Pasalic <[EMAIL PROTECTED]> rough code, to give you an idea: ('".mysql_real_escape_string($first)."', '".mysql_real_escape_string($last)."') "); } else { $query = mysql_query(" select first, last from table where id=xyz ")

Re: [PHP] Reload page after form submit

2007-08-30 Thread Afan Pasalic
rough code, to give you an idea: ('".mysql_real_escape_string($first)."', '".mysql_real_escape_string($last)."') "); } else { $query = mysql_query(" select first, last from table where id=xyz "); $result = mysql_fetch_array($query,

RE: [PHP] Reload page after form submit

2007-08-30 Thread Instruct ICC
From: "Wagner Garcia Campagner" <[EMAIL PROTECTED]> Is there a way to tell PHP to reload the page after the user submit the information, so the page is always updated?? Thanks in advance, Wagner. I don't get your fundamental problem. When a user submits a form, the page handling the submissio

RE: [PHP] Reload page after form submit

2007-08-30 Thread Instruct ICC
From: "Wagner Garcia Campagner" <[EMAIL PROTECTED]> Hello, I'm building a web page just like a blog... Where the user input some information... (name, website and comment) This information is stored in a file... And then the page displays it... When the user access the page the first time, t

Re: [PHP] Reload page after form submit

2007-08-30 Thread Stut
Wagner Garcia Campagner wrote: Thanks a lot, I tried both suggestions, but it didn't work... I did it send an Echo with this string: After processing the form... it worked... Is there any problem doing this? You'd be better off with... header('Location: index.php'); Although technically

RE: [PHP] Reload page after form submit

2007-08-30 Thread Wagner Garcia Campagner
EMAIL PROTECTED] Sent: quinta-feira, 30 de agosto de 2007 14:44 To: Per Jessen Cc: php-general@lists.php.net Subject: Re: [PHP] Reload page after form submit On 30/08/2007, Per Jessen <[EMAIL PROTECTED]> wrote: > > Wagner Garcia Campagner wrote: > > > Hello, > > > > I&

Re: [PHP] Reload page after form submit

2007-08-30 Thread Wouter van Vliet / Interpotential
On 30/08/2007, Per Jessen <[EMAIL PROTECTED]> wrote: > > Wagner Garcia Campagner wrote: > > > Hello, > > > > I'm building a web page just like a blog... > > > > Where the user input some information... (name, website and comment) > > > > This information is stored in a file... > > > > And then the

Re: [PHP] Reload page after form submit

2007-08-30 Thread Per Jessen
Wagner Garcia Campagner wrote: > Hello, > > I'm building a web page just like a blog... > > Where the user input some information... (name, website and comment) > > This information is stored in a file... > > And then the page displays it... > > When the user access the page the first time, t

[PHP] Reload page after form submit

2007-08-30 Thread Wagner Garcia Campagner
Hello, I'm building a web page just like a blog... Where the user input some information... (name, website and comment) This information is stored in a file... And then the page displays it... When the user access the page the first time, the information is displayed correct... After the user