0

I have php application on Hostinger and use mail() function to send emails to my clients. When I send short text massage they receive it but when I exceed special limitation on my text character Host successfully send it but costumer cannot receive email.

It is very weird because I have exactly this code on another Hostinger account and I don't have the same problem! On that account with exactly this code I send long text emails and costumers receive them.

There is my email testing code which obviously is not problem because it has been working for over 2 years on my other account on Hostinger:


 $content='
        hi admin,

There is a new order to sweet
with the reference number 47 from customer Josef  Saliba

        <!--<div style="display: block;max-height: 70px;max-width: 200px;">-->
                <!--</div>-->
        <table border="0">
        <tr><td>Customer Name</td><td>Josef  Saliba</td></tr><tr><td>Merchant Name</td><td>sweetnfresh</td></tr><tr><td>Telephone</td><td>sweetnfresh</td></tr><tr><td>Address</td><td>999 8 St SW Calgary AB T2R1J5</td></tr><tr><td>TRN Type</td><td>delivery</td></tr><tr><td>Payment Type</td><td>COD</td></tr><tr><td>Reference #</td><td>47</td></tr><tr><td>TRN Date</td><td>Aug 24,2022 3:09:10 am</td></tr><tr><td>Delivery Date</td><td>Aug 24,2022</td></tr><tr><td>Deliver ASAP</td><td>Yes</td></tr><tr><td>Deliver to</td><td>calgary  calgary ALBERTA </td></tr><tr><td>Delivery Instruction</td><td></td></tr><tr><td>Location Name</td><td></td></tr><tr><td>Contact Number</td><td>+1343243242</td></tr><tr><td colspan="2">&nbsp;</td></tr><tr><td colspan="2"><b></td></b></tr><tr><td>1 Oldenburger 100% Rye</td><td>&#36;8.29</td></tr><tr><td colspan="2">&nbsp;</td></tr><tr><td>Sub Total:</td><td>&#36;8.29</td></tr><tr><td>Delivery Fee:</td><td>&#36;1.99</td></tr><tr><td>Tax 5%</td><td>&#36;0.41</td></tr><tr><td>Tips 10%:</td><td>&#36;1.22</td></tr><tr><td>Service Fee:</td><td>&#36;1.50</td></tr><tr><td>Total:</td><td>&#36;13.41</td></tr>      
        </table>
        

Kind Regards';
        sendEmail(                        //my mailing function
                  's****@gmail.com', //to
                  'info@g**.ca', //from
                  'test', //subject
                 $content,
                  20000
                );
  • Can you provide details about where this limit is coming from? Do you have logs on the server you can provide? I know you edited the title to say that the messages are getting sent; what is your evidence for that? – Stephen Ostermiller Aug 25 '22 at 09:23
  • Problem is solved! I just used wordwrap() for my text and it works successfully now! – shayan izadi Aug 26 '22 at 14:53

0 Answers0