Re: Re[2]: [PHP] Program that'll parse HTML form with results and send HTML email?

From: Date: Tue, 20 Apr 2004 14:05:08 +0000
Subject: Re: Re[2]: [PHP] Program that'll parse HTML form with results and send HTML email?
References: 1 2 3 4  Groups: php.general 
Request: Send a blank email to php-general+get-183989@lists.php.net to get a copy of this message
From: "Tom Rogers" <trogers@kwikin.com> > It does not need to know the form elements, only the reserved words it > uses and you take those out and pass them directly to the class if > needed. It takes the variable name from the POST array and uses it with > the value. No need to know what the input fields are called or even > what type - checkboxes and radio groups work fine. Okay, I see what you mean. >default: //not a keyword >$k = ereg_replace("_"," ",$k); //get rid of _ and replace with a space >if($v == "BR"){ //if BR add a carriage return,used for making blank line > $this->vars['blocks']['submit'][$x]['ifs']['break'] > = '&nbsp;'; > $this->text .= "\n"; >}else{ > $this->vars['blocks']['submit'][$x]['vars']['name'] > = $k; > > $this->vars['blocks']['submit'][$x]['vars']['value'] = > $v; > $this->text .= "$k : $v\n"; //add the variable name and value to email > } I see what you're doing here, but it doesn't fit what I'm looking for exactly. You just create a Key : Value list to include in the email. I want the email to look exactly like the form, only substitute in the values submitted by the user. ---John Holmes...

« previous php.general (#183989) next »