Jump to content

gigas10

Members
  • Posts

    64
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

gigas10's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. im getting the built in error in the code, which says Could not send to your email. So its failing on if($sentmail)
  2. mktime would convert it to a unix timestamp
  3. nope no luck, there must be something configured incorrectly with the server or mail server. Although i cant do anything about it
  4. so what do i do? just use the smtp server for the sentfrom ?
  5. They all are, this is run on intranet, a huge company. Everyone that will be requesting a password sent to their email will be registered to the system used here and have an account set up already.
  6. so your telling me you cant email yourself? i do it all the time
  7. nope like i stated i already filled that stuff in, the sendmail path is only for unix? so that doesnt make sense that its the solution. And sendmail_from just gets over ridden by my headers
  8. Hey everyone, i've got a little problem with the mail() function. So to clarify i'm unluckily running php with IIS and mssql. I'm trying to do send mail to someone if they forgot their password, however when I send mail it always fails. Here is the part of my phpinfo() page, the smtp server is set up correctly because it mails in asp just fine. sendmail_from no value no value sendmail_path no value no value also my code <?php require_once('connectdb.php'); $tnum = $_POST['tnum']; $qry = mssql_query("SELECT passwd, email FROM members WHERE TNumber='$tnum'"); $result = mssql_num_rows($qry); if($result == 1) { $rows=mssql_fetch_array($qry); // keep password in $your_password $your_password=$rows['passwd']; // ---------------- SEND MAIL FORM ---------------- // send e-mail to ... $to=$rows['email']; // Your subject $subject="Forgotten Password"; // From $header="From: $to"; // Your message $messages= "Your password for login to our website \r\n"; $messages.="Your password is $your_password \r\n"; $messages.="more message... \r\n"; // send email $sentmail = mail($to,$subject,$messages,$header); } // else if $count not equal 1 else { echo "Could not find your email in our database<Br> "; } // if your email succesfully sent if($sentmail){ echo "Your Password Has Been Sent To Your Email Address."; echo "<a href=login-form.php>Login Page</a>"; } else { echo "Cannot send password to your e-mail address<br>"; echo $to; } ?>
  9. did u restart the apache server? did u install apache before or after php?
  10. $name = $row['Column_Name_Which_Stores_The_Users_Name']; $sex = $row['Column_Name_Which_Stores_The_Users_Sex']; $musictype = $row['Column_Name_Which_Stores_The_Users_Musictype']; echo $name; or echo "<tr><td>Name</td></tr><tr><td>" . $name . "</td></tr>";
  11. it can be done with vb, but it is impossible to do with php sryz
  12. select * from table order by asc limit 3 select * from table where id > 3 order by asc limit 2 why would you even want to do this?
  13. i bet you didnt install the mysql extensions when u installed php :-x
  14. ya im an idiot and this was worded very badly, anywho i just went with a different method, onclick and a function to switch to the page.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.