Jump to content


Photo

Need Help Sending Email With Php


  • Please log in to reply
6 replies to this topic

#1 dlc3172

dlc3172

    Member

  • Members
  • PipPip
  • 13 posts

Posted 10 December 2012 - 09:55 PM

Hi All -

I'm not a programmer whatsoever. Just trying to implement a login/registration system into my web site. I've purchased a script that does what I need. However, after installing the script, I'm finding that it refuses to send email like it should (i.e., send confirmation email to new users; send forgotten password email, etc.).

My hosting service is Yahoo. Yahoo's help section says this about sending email with PHP:

"You will also need to indicate the path to the Yahoo! mail program, Sendmail. The path to Sendmail is /usr/sbin/sendmail."

I honestly have no idea where or how I'm supposed to put this into the code. I'm hoping someone can help me.

I've attached two files, one is the sign-up.php file. The other is called signup.class.php, and I think this is where the mail gets sent from. But I'm not positive. Can anyone help? Much appreciated!!!

Attached Files



#2 SocialCloud

SocialCloud

    Advanced Member

  • Members
  • PipPipPip
  • 619 posts

Posted 10 December 2012 - 10:07 PM

Yahoo should be automatically setting up the path...if not you, need a new host.

#3 dlc3172

dlc3172

    Member

  • Members
  • PipPip
  • 13 posts

Posted 11 December 2012 - 01:08 PM

Yahoo should be automatically setting up the path...if not you, need a new host.


I thought Yahoo was saying that I needed to add "usr/sbin/sendmail" to my php code. No??

#4 Jessica

Jessica

    This is not my name.

  • Gurus
  • 8,982 posts
  • LocationDallas, TX
  • Age:26

Posted 11 December 2012 - 09:09 PM

Change it in your PHP.ini
http://php.net/manua...nfiguration.php
My goal in replying to posts is to help you become a better programmer, including learning how to debug your own code and research problems. For that reason, rather than posting the solution, I reply with tips and hints on how to find the solution yourself. See below for useful links when you get stuck.

How to Get Good Help: How to Ask Questions | Don't be a help vampire
Debugging Your Code: Debugging your SQL | What does a php function do? | What does a term mean? | Don't see any errors?
Things You Should Do: Normalize Your Data | use print_r() or var_dump()
Lulz: "Functions should not have side effects." - trq

Please take a look at my new PHP/Web Dev blog: The Web Mason - Thanks!!

#5 dlc3172

dlc3172

    Member

  • Members
  • PipPip
  • 13 posts

Posted 12 December 2012 - 10:06 AM

Thank you Jessica. I am assuming php.ini is a file that lives somewhere in my account on my host's server?

#6 happypete

happypete

    Advanced Member

  • Members
  • PipPipPip
  • 116 posts

Posted 17 December 2012 - 08:57 PM

This is your second thread with problems receiving email.

The script in the previous thread uses the mail() function so send email, it may be your web host has disabled it for security reasons. My current web host disabled it on their servers a year ago so I chnaged to use SMTP with PHPMailer:

http://forums.phpfre...-form-use-smtp/

#7 Stilter

Stilter

    Newbie

  • New Members
  • Pip
  • 1 posts

Posted 28 December 2012 - 11:53 AM

Somewhere in the script you have purchased there will be a line that sets a variable to the path to 'sendmail'. Hopefully, there will be some notation in the script to give you a clue. In the script I have(phpmailer) the variable is $Sendmail and the notation (surrounded by comment tags /* notes */) says; "Sets the path to sendmail program." Different servers will have slightly different directory names in the path. Make sure you copy it exactly.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

Cheap Linux VPS from $5
SSD Storage, 30 day Guarantee
1 TB of BW, 100% Network Uptime

AlphaBit.com