Welcome Guest, Not a member yet? Register   Sign In
email sent with no error, but didn't arrived
#1

[eluser]davidino86[/eluser]
hi,
i'm trying to send an email from a form in the contact page with a javascript validation and sent to www.mysite.com/email/send

this is the controller code:

Code:
<?php

Class Email extends Controller
{
    function email()
    {
        parent::Controller();
     $this->load->library('email');
    }

    function send()
    {
        $service = $_POST['service'];
        $date = $_POST['date'];
        $from = $_POST['from'];
        $address_from = $_POST['address_from'];
        $to = $_POST['to'];
        $address_to = $_POST['address_to'];
        $pax= $_POST['pax'];
        $name= $_POST['name'];
        $surname= $_POST['surname'];
        $email= $_POST['email'];
        $note= $_POST['note'];

      
        $config['mailtpye'] = 'html';
        $this->email->from($address_from, $name);
        $this->email->to('[email protected]');
        


        $this->email->subject('preventivo richiesto da limousineuara.comt');
        $this->email->message('

<style>table {font-family:"arial";} td {border:"dotted 1px #000"; height:"60px";}span {color:"#990000";} p {margin:"0"; font-weight:"bold";}</style>


<table width="100%" border="0">
  <tr>
    <td>Date of Service:</td>
    <td>'.$date.'</td>
  </tr>
  <tr>
    <td>Type of Service:</td>
    <td>'.$service.'</td>
  </tr>
  <tr>
    <td>From:<br />
        <span class="desc">(city, airport, port, hotel, train station ...)</span></td>
        <td>'.$from.' </td>
  </tr>
  <tr>
    <td>From Address:</td>
    <td>'.$address_from.'</td>
  </tr>
  <tr>
    <td>To:<br />
        <span class="desc">(city, airport, port, hotel, train station ...)</span></td>
        <td>'.$to.'</td>
  </tr>
  <tr>
    <td>To Address:</td>
    <td>'.$address_to.'</td>
  </tr>
  <tr>
    <td>Number of PAX:</td>
    <td>'.$pax.'</td>
  </tr>
  <tr>
    <td>Name:</td>
    <td>'.$name.'</td>
  </tr>
  <tr>
    <td>Surename:</td>
    <td>'.$surname.'</td>
  </tr>
  <tr>
    <td>email:</td>
    <td>'.$email.'</td>
  </tr>
  <tr>
    <td>Note:</td>
    <td>'.$note.'</td>
  </tr>
</table>');

       if($this->email->send()) {
          redirect(base_url());
       }else{
           echo "Error";
       }

        

    }
}

?&gt;

i don't know why can someone tell where is the error?

thank you
davide


Messages In This Thread
email sent with no error, but didn't arrived - by El Forum - 09-02-2009, 10:21 AM
email sent with no error, but didn't arrived - by El Forum - 09-02-2009, 10:30 AM
email sent with no error, but didn't arrived - by El Forum - 09-03-2009, 02:37 AM
email sent with no error, but didn't arrived - by El Forum - 09-03-2009, 02:49 AM
email sent with no error, but didn't arrived - by El Forum - 09-03-2009, 03:02 AM



Theme © iAndrew 2016 - Forum software by © MyBB