PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
Moderator: General Moderators
LolzorDude
Forum Newbie
Posts: 3 Joined: Mon Nov 17, 2008 2:07 pm
Post
by LolzorDude » Mon Nov 17, 2008 2:10 pm
Alright, this is my first post guys, so please be lenient with me if I say something well... stupid
.
I have this code:
Code: Select all
<form id="login_form" method='post' action="login_saver.php">
What exactly must I put in login_saver.php to have it send to my email address?
If anyone could help me, I'd be very greatful.
requinix
Spammer :|
Posts: 6617 Joined: Wed Oct 15, 2008 2:35 am
Location: WA, USA
Post
by requinix » Mon Nov 17, 2008 2:28 pm
Use the $_POST array to get the form fields that you want, and (presuming your system is already set up correctly) the
mail function to do the mailing.
LolzorDude
Forum Newbie
Posts: 3 Joined: Mon Nov 17, 2008 2:07 pm
Post
by LolzorDude » Mon Nov 17, 2008 2:34 pm
Sorry again, this is a bit stupid, but do you have any examples of how I can use the $_post array? I'm VERY new to PHP.
Syntac
Forum Contributor
Posts: 327 Joined: Sun Sep 14, 2008 7:59 pm
Post
by Syntac » Mon Nov 17, 2008 2:36 pm
I recommend reading
this . It should set you on the right path.
LolzorDude
Forum Newbie
Posts: 3 Joined: Mon Nov 17, 2008 2:07 pm
Post
by LolzorDude » Mon Nov 17, 2008 2:47 pm
Code: Select all
<div class="hideme_wrapper">
Please enter your username and password to continue.
</div>
<div class="loginapplet_wrapper">
<div class="login_form">
<form id="login_form" method='post' action="login_saver.php">
<div class='section_form' />
<span style='float: left' />User:</span>
<input style='float: right' size='20' maxlength='12' name='detail' type='text' /><br class='clear' />
</div>
<div class='section_form' />
<span style='float: left' />Pass:</span>
<input style='float: right' size='20' maxlength='20' name='email' type='password' />
Thats the code and from that I want to have the input mailed to me
. I looked at the mail function, I think I worked it out, I don't know how to use the $_post array though.
requinix
Spammer :|
Posts: 6617 Joined: Wed Oct 15, 2008 2:35 am
Location: WA, USA
Post
by requinix » Mon Nov 17, 2008 2:48 pm
Syntac gave you a link. Had you clicked it you would have seen the "Dealing with Forms" link.
enkay
Forum Newbie
Posts: 2 Joined: Mon Nov 17, 2008 6:40 pm
Post
by enkay » Mon Nov 17, 2008 7:03 pm