Re: [PHP] form submission error trapping

2002-02-25 Thread George Whiffen
Navid, $SCRIPT_NAME is sometimes a safer alternative than $PHP_SELF. The difference is that $PHP_SELF includes $PATH_INFO while $SCRIPT_NAME is just the name of the actual script running. http://www.php.net/manual/en/language.variables.predefined.php This becomes particularly important if you u

RE: [PHP] form submission error trapping

2002-02-20 Thread Jason Dulberg
quot;; } ".$error['username'];?> ".$error['password'];?> Am I assigning errors to the array incorrectly? Thanks for your help :) Jason > -Original Message- > From: Jason G. [mailto:[EMAIL PROTECTED]] > Sent: February 18, 2002 9:19 AM > To

RE: [PHP] form submission error trapping

2002-02-19 Thread Navid Yar
hanks... Navid -Original Message- From: George Whiffen [mailto:[EMAIL PROTECTED]] Sent: Monday, February 18, 2002 7:09 AM To: Navid Yar Subject: Re: [PHP] form submission error trapping Navid, $SCRIPT_NAME is sometimes a safer alternative than $PHP_SELF. The difference is that $PHP_SELF includes $

Re: [PHP] form submission error trapping

2002-02-18 Thread Jason G.
Why do not you all just put all your PHP logic, db access, etc at the TOP of the script. Once you have your results and variables created, then start into html. This method produces MUCH cleaner scripts, and there is a very minimal amount of PHP interspersed within the HTML. Also, you have ti

Re: [PHP] form submission error trapping

2002-02-18 Thread Matt
I think that mixing of html and php is too complex and leads to hard to maintain scripts. I find it extremely difficult to understand a scripts logic when it's spread out over hundreds of lines of php/html. I use EasyTemplates that came in Web Applications Development with PHP 4.0 by Tobias Ratsc

RE: [PHP] form submission error trapping

2002-02-18 Thread Jill . Baker
to fill in this field\n"; } echo ""; etc. > -Original Message- > From: Jason Dulberg [SMTP:[EMAIL PROTECTED]] > Sent: Sunday, February 17, 2002 23:40 > To: Martin Towell > Cc: [EMAIL PROTECTED] > Subject: RE: [PHP] form submission error trapping

RE: [PHP] form submission error trapping

2002-02-17 Thread Navid Yar
Simply, to send a form to itself, you can use a special variable called $PHP_SELF. Here's an example of how to use it: if ($somevalue) { header("Location: $PHP_SELF"); } else { execute some other code... } Here, if $somevalue holds true, it will call itself and reload the same script/file.

Re: [PHP] form submission error trapping

2002-02-17 Thread Steven Walker
Yeah, for buttons (radio/checkboxes) I had to put an if statement on each one: > unformatted > You're right... it's not as easy. Steven J. Walker Walker Effects www.walkereffects.com [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To un

RE: [PHP] form submission error trapping

2002-02-17 Thread Martin Towell
2002 10:40 AM To: Martin Towell Cc: [EMAIL PROTECTED] Subject: RE: [PHP] form submission error trapping Thanks for the code Is there a way to keep track of what fields had the errors as its possible for people to have like 5 errors? Thanks again. Jason -Original Message- From: M

Re: [PHP] form submission error trapping

2002-02-17 Thread Steven Walker
> I guess the real challenge is converting a pre-existing page like the > one I've described into one that can re-populate itself on an error > condition. Building it that way from scratch is merely a programming > task. That's true, however there are a few ways to cheat :). For example, in

RE: [PHP] form submission error trapping

2002-02-17 Thread Jason Dulberg
, 2002 6:41 PM To: '[EMAIL PROTECTED]'; Steven Walker Cc: [EMAIL PROTECTED] Subject: RE: [PHP] form submission error trapping something like: not tested but should work - just expand on it Martin -Original Message- From: Jas

RE: [PHP] form submission error trapping

2002-02-17 Thread Ken
> > -Original Message- > > From: Steven Walker [mailto:[EMAIL PROTECTED]] > > > > I created one php page that both displays the form and validates the > > input. When the user hits the submit button, it submits the data to > > itself. If anything is missing from the page, the form is r

RE: [PHP] form submission error trapping

2002-02-17 Thread Martin Towell
; -Original Message- > From: Steven Walker [mailto:[EMAIL PROTECTED]] > Sent: February 17, 2002 6:18 PM > To: [EMAIL PROTECTED] > Cc: [EMAIL PROTECTED] > Subject: Re: [PHP] form submission error trapping > > > Jason, > > I just finished one of my form

RE: [PHP] form submission error trapping

2002-02-17 Thread Jason Dulberg
; -Original Message- > From: Steven Walker [mailto:[EMAIL PROTECTED]] > Sent: February 17, 2002 6:18 PM > To: [EMAIL PROTECTED] > Cc: [EMAIL PROTECTED] > Subject: Re: [PHP] form submission error trapping > > > Jason, > > I just finished one of my form pages, a

Re: [PHP] form submission error trapping

2002-02-17 Thread Steven Walker
Jason, I just finished one of my form pages, and I'm really happy with how it turned out. I created one php page that both displays the form and validates the input. When the user hits the submit button, it submits the data to itself. If anything is missing from the page, the form is reshown

RE: [PHP] form submission error trapping

2002-02-17 Thread Martin Towell
submit back to the same page - or include that page Martin -Original Message- From: Jason Dulberg [mailto:[EMAIL PROTECTED]] Sent: Monday, February 18, 2002 9:23 AM To: [EMAIL PROTECTED] Subject: [PHP] form submission error trapping I am working on some error trapping for several forms