SitePoint Sponsor

User Tag List

Results 1 to 7 of 7
  1. #1
    SitePoint Addict
    Join Date
    Sep 2008
    Posts
    235
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    mail function problem ( linux , godaddy )

    in this php code the data is posted from a form and will be mailed to my e-mail

    but my problem is that when Using the php mail function with godaddy , i did not receive the mail

    the system is linux



    and for more details for phpinfo click on the following link

    http://projects.kayandco-egypt.com/untitled2_old.php

    really i need help to fix this problem today.....

    i tried to see many forums but i dont have the solutions yet
    i tried also to use phpmailer but it did not help me

    if anyone have a function or any solution for this problem plz send for me
    PHP Code:
    <?
    session_start
    ();
    header("Cache-control: private"); // IE 6 Fix

    if ($_POST["name"])

    {




    foreach (
    $_POST as $key => $value) {

    $
    $key trim($value);
    $_SESSION[$key "_b"] = $value;
    // echo "Key: $key; Value: $value<br />\n";

    }

    $kind "mail";




    $messageo '

    <html>
    <head>
    <style>

    body {

    font-family: Arial, Helvetica, sans-serif;
    font-size: 11px;
    color: #737373;
    text-align: justify;
    width: auto;
    margin-right: 0px;
    margin-left: 0px;
    margin-top: 10px;
    margin-bottom: 10px;
    line-height: 17px;
    }
    .padding {
    padding-left: 30px;
    background-color: #cdcdcd;
    color: #023061;
    height: 30px;
    vertical-align: middle;
    }
    .padding2 {
    padding-left: 30px;
    background-color: #E5E5E5;
    color: #023061;
    height: 30px;
    }

    .title1 {
    font-size: 17px;
    font-weight: bold;
    color: #023061;
    padding-top: 20px;
    padding-bottom: 25px;
    font-family: Arial, Helvetica, sans-serif;
    text-transform: uppercase;
    }

    </style>

    </head>
    <body>
    <div class="title1" align="center">mail</div>
    <table width="50%" border="0" cellspacing="1" cellpadding="4" align="center">
    <tr class="padding">
    <td width="30%"><strong>Name <b></strong> </td>
    <td >' 
    $name '</td>
    </tr>

    <tr class="padding2">
    <td ><strong>E-mail </strong> </td>
    <td >' 
    $emal '</td>
    </tr>



    <tr class="padding">
    <td><strong> City </strong> </td>
    <td>' 
    .$city '</td>
    </tr>
    <tr class="padding2">
    <td><strong>Country</strong> </td>
    <td>'
    .$country.'</td>
    </tr>
    <tr class="padding">
    <td><strong>Telephone</strong> </td>
    <td>' 
    $tel.'</td>
    </tr>
    </table> 

    </body>
    </html> '
    ;



    //echo $message;



    $headers .= "MIME-Version: 1.0\r\n"
    $headers .= "Content-type: text/html; charset=windows-1256\r\n";
    $headers .= "From: info@abcc.com>\r\n";
    $headers .= "cc: abc@abc.com\r\n";


    $ok mail("abc@abc.com"$kind$messageo$headers); 


    }
    header("Location: welcome.php"); 
    ?>

  2. #2
    SitePoint Member
    Join Date
    Jan 2009
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Did you check your junk email or spam email folders

  3. #3
    SitePoint Addict
    Join Date
    Sep 2008
    Posts
    235
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    yes i did , but i did not receive the mail....

    i dont know how i can slove this problem?
    can anyone have a php different mail function that can work on godaddy with linux?
    thnx alot

  4. #4
    SitePoint Addict
    Join Date
    Sep 2008
    Posts
    235
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    tried to send mails through another server and it works very very well
    but i dont know why it did not work with godaddy

    the problem is that i must use godday and i must send mails through godaddy



    the difference between the working server and godaddy

    the server taht is working well

    safe_mode Off Off
    safe_mode_exec_dir no value no value
    safe_mode_gid Off Off
    safe_mode_include_dir no value no value
    sendmail_from no value no value
    sendmail_path /usr/sbin/sendmail -t -i /usr/sbin/sendmail -t -i
    serialize_precision 100 100
    short_open_tag On On
    SMTP localhost localhost
    smtp_port 25 25
    sql.safe_mode Off Off
    track_errors Off Off


    the link of the working server is
    http://www.graphicano.com/john/untitled2_old.php


    the server taht is not working well


    register_globals Off Off
    register_long_arrays Off Off
    report_memleaks On On
    report_zend_debug On On
    safe_mode Off Off
    safe_mode_exec_dir no value no value
    safe_mode_gid Off Off
    safe_mode_include_dir ~ ~
    sendmail_from me@localhost.com me@localhost.com
    sendmail_path /usr/sbin/sendmail -t -i /usr/sbin/sendmail -t -i
    serialize_precision 100 100
    short_open_tag On On
    SMTP relay-hosting.secureserver.net relay-hosting.secureserver.net
    smtp_port 25 25


    the link of the non working server (godaddy)

    http://projects.kayandco-egypt.com/untitled2_old.php



    please urgently i need help or a full mail funciton and i wil modify it,,

    plz i need it

  5. #5
    SitePoint Zealot
    Join Date
    Oct 2008
    Posts
    167
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Try changing the line:

    PHP Code:
    $ok mail("abc@abc.com"$kind$messageo$headers); 
    to

    PHP Code:
    $ok mail("abc@abc.com"$kind$messageo$headers"-finfo@abcc.com"); 
    CanisHosting - Web Hosting plans starting at $3.95 per month

  6. #6
    SitePoint Addict
    Join Date
    Jul 2008
    Location
    sudo rm -rf /
    Posts
    386
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    If you still can not send mail with the mail function use the phpmailer class to send mail with smtp(gmail,yahoo).
    http://phpmailer.sf.net

  7. #7
    SitePoint Addict
    Join Date
    Sep 2008
    Posts
    235
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by buldozerce View Post
    If you still can not send mail with the mail function use the phpmailer class to send mail with smtp(gmail,yahoo).
    http://phpmailer.sf.net
    i asked godaddy support and they told me that i must search about
    1-
    The path to sendmail on our Linux hosting servers is:

    /usr/sbin/sendmail

    2- you will need to use relay-hosting.secureserver.net

    till now i did not solve this problem and really i need help
    can phpmailer solve this problem??
    i tried to use it but it did not work correclty? may be i made an error , but i need to know if i use it? can it help me to send mails?? or can anyone help me to use phpmailer?


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •