Sending formmail results to user submitted email address

  • AnthonyF
  • Novice
  • Novice
  • User avatar
  • Posts: 28

Post 3+ Months Ago

Hey all,

My problem is simple....


I need my cgi form to submit to a required field contained within the form. IE, field 1 is for an email address, and the submit_to call needs to submit via sendmail to this field 1 email address. Simple huh

Well I must be retarded because I can't figure it out.. anyone have a clue?
  • AnthonyF
  • Novice
  • Novice
  • User avatar
  • Posts: 28

Post 3+ Months Ago

This a dumb question? If it is just let me know and I'll do more research....
  • RichB
  • Guru
  • Guru
  • User avatar
  • Posts: 1121
  • Loc: Boston

Post 3+ Months Ago

I think the standard way of specifying a recipient address for a formmail script is with a hidden field:

Code: [ Select ]
<input type="hidden" name="recipient" value="email@your.host.com">
  • AnthonyF
  • Novice
  • Novice
  • User avatar
  • Posts: 28

Post 3+ Months Ago

No, I mean like when viewing the form on an HTML page, there will be a area where they can enter an email address to submit the form to as well as the ones listed in the hidden 'recepient' field.

NE clue?
  • gsv2com
  • Professor
  • Professor
  • User avatar
  • Posts: 776
  • Loc: Nippon

Post 3+ Months Ago

This would be very easy to explain in PHP. Do you prefer Perl or would PHP be ok? I've made quite a few scripts like this.
  • AnthonyF
  • Novice
  • Novice
  • User avatar
  • Posts: 28

Post 3+ Months Ago

We can try in PHP - my knowledge of PHP is limited to an install of osCommerce tho.
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23455
  • Loc: Woodbridge VA

Post 3+ Months Ago

I haven't done it in a long time, but I think this would work:

Code: [ Select ]
<input type="text" name="cc" value="">


If it helps here's a list of email form variables that can be used:
http://alumweb.mit.edu/reference/email/4.shtml

By leaving value="" blank, it should assume whatever is inputed in the text field for the cc variable.
  • AnthonyF
  • Novice
  • Novice
  • User avatar
  • Posts: 28

Post 3+ Months Ago

slicckk.... that did it. Thanks bro, ur a smart mofo!
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23455
  • Loc: Woodbridge VA

Post 3+ Months Ago

Glad it helped you AnthonyF.

Post Information

  • Total Posts in this topic: 9 posts
  • Users browsing this forum: No registered users and 77 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.