ppmt

Forum Replies Created

Viewing 15 posts - 31 through 45 (of 56 total)
  • Author
    Posts
  • in reply to: PDF rendering vs Print Preview #664
    ppmt
    Participant

    I have tried to play a bit with using div and span rather that table. I also tried to use css grid…
    But whatever I try I can get it to display well in the html version (print icon) but if I render it to PDF it just doesn’t render the same.

    The default theme has the same behaviour

    in reply to: new line in invoices not fully populated #663
    ppmt
    Participant

    any opinion on this issue?

    in reply to: PDF rendering vs Print Preview #662
    ppmt
    Participant

    Hum…turns out that apparently float and clear are not supported for table in mpdf

    https://stackoverflow.com/questions/51579343/mpdf-float-not-working-for-tables

    time for a reflow of my template 🙂

    in reply to: Debugging email #651
    ppmt
    Participant

    Uploaded and tested. It works

    Glad it got sorted 🙂

    in reply to: Debugging email #649
    ppmt
    Participant

    how about using

    $config->email->secure ?

    it works for me if I do that

    in reply to: Debugging email #643
    ppmt
    Participant

    Right!!!!!

    I managed to send an email at last!

    But I had to modify the file Inc/Claz/Email.php line 81 to add ssl like this:

    $transport = new Swift_SmtpTransport($config->email->host, $config->email->smtpport<strong>, 'ssl'</strong>);

    is there any reason why the email.secure from custom.config.php is not used?

    in reply to: Debugging email #642
    ppmt
    Participant

    I have been having a long email exchange with the support people at byethost. In the end we could not find the problem but they pointed me to some script example using Switmailer.

    Here is the script swiftmailer.php I have written and put in /modules/invoices:

    
    <?php
    use Inc\Claz\Email;
    print_r( stream_get_transports());
    // Create the Transport
    $transport = (new Swift_SmtpTransport('sv4.byethost4.org', 290, 'ssl'))
      ->setUsername('myusername')
      ->setPassword('mypassword')
      ;
    
    // Create the Mailer using your created Transport
    $mailer = new Swift_Mailer($transport);
    
    // Create a message
    $message = (new Swift_Message('The Subject'))
      ->setFrom(['fromemail@mydomain' => 'John Doe'])
      ->setTo(['toemail@myotherdomain' => 'A name'])
      ->setBody('Here is the message itself')
      ;
    
    // Send the message
    $result = $mailer->send($message);
    ?>

    I then use http://myserver/index.php?module=invoices&view=swiftmail to execute it.
    and it works. The email is sent and received.

    Now if I set the custom.config.php to use the same data like this

    email.host                          = sv4.byethost4.org
    email.smtp_auth                     = true
    email.username                      = myusername
    email.password                      = mypassword
    email.smtpport                      = 290
    email.secure                        = ssl
    email.ack                           = false
    email.use_local_sendmail            = false

    if I then try to send an email the normal then it fails with the Timed Out error!

    I don’t understand!!

    in reply to: Debugging email #638
    ppmt
    Participant

    yes I think they are good. Was there any reason you decided to switch to swiftmailer?

    in reply to: Debugging email #633
    ppmt
    Participant

    me again.

    I decided to install a version on SI on my hosted account with byethost and originally I had the exact same problem.

    They advised me to use port 384 instead of 290 and success it worked!!!

    Only problem is that using the same port on my locally hosted is still not working. But I get a different error this time in php.log. I have replaced the name of the hostname and its ip in the log.

    [04-Oct-2019 04:01:34 America/Los_Angeles] PHP Fatal error:  Uncaught Swift_TransportException: Expected response code 354 but got code "503", with message "503-All RCPT commands were rejected with this error:^M
    503-Please turn on SMTP Authentication in your mail client.  <hostname>^M
    503-(invoices.master2019.org) [<my IP>]:60170 is not permitted to relay^M
    503-through this server without authentication.^M
    503 Valid RCPT command must precede DATA^M
    " in /var/www/simpleinvoices/simpleinvoices-master_2019.2/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php:457
    Stack trace:
    #0 /var/www/simpleinvoices/simpleinvoices-master_2019.2/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php(341): Swift_Transport_AbstractSmtpTransport->assertResponseCode('503-All RCPT co...', Array)
    #1 /var/www/simpleinvoices/simpleinvoices-master_2019.2/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/EsmtpTransport.php(305): Swift_Transport_AbstractSmtpTransport->executeCommand('DATA\r\n', Array, Array, false, N in /var/www/simpleinvoices/simpleinvoices-master_2019.2/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php on line 457
    
    in reply to: Debugging email #632
    ppmt
    Participant

    I tried with SSL and TLS and got the same printout in both case

    2019-09-29T11:19:09-07:00 DEBUG (7): init.php - authentication-enabled[] fake_auth[1]
    2019-09-29T11:19:09-07:00 DEBUG (7): index.php - After init.php - module(invoices] view[email]
    2019-09-29T11:19:09-07:00 DEBUG (7): index.php - After processing init.php for extensions
    2019-09-29T11:19:09-07:00 DEBUG (7): index.php - module[invoices] view[email] databaseBuilt[1] databasePopulated[1]
    2019-09-29T11:19:09-07:00 DEBUG (7): index.php - apply_db_patches[1]
    2019-09-29T11:19:09-07:00 DEBUG (7): index.php - config->authentication->enabled[] auth_session->id: 1
    2019-09-29T11:19:09-07:00 DEBUG (7): index.php - module - invoices
    2019-09-29T11:19:09-07:00 DEBUG (7): index.php - still_doing_setup[]
    2019-09-29T11:19:09-07:00 DEBUG (7): index.php - module[invoices] view[email] action[] id[1] menu[1]
    2019-09-29T11:19:09-07:00 DEBUG (7): index.php - After invoices/template
    2019-09-29T11:19:09-07:00 DEBUG (7): index.php - After api/xml or ajax
    2019-09-29T11:19:09-07:00 DEBUG (7): index.php - After extension_jquery_files
    2019-09-29T11:19:09-07:00 DEBUG (7): index.php - after custom/hooks.tpl
    2019-09-29T11:19:09-07:00 DEBUG (7): index.php - after header.tpl
    2019-09-29T11:19:09-07:00 DEBUG (7): index.php - After extension_php_insert_files, etc.
    2019-09-29T11:19:09-07:00 DEBUG (7): index.php - my_path[modules/invoices/email.php]
    2019-09-29T11:19:09-07:00 DEBUG (7): email.php - _GET stage[2]
    2019-09-29T11:19:09-07:00 DEBUG (7): Export::getData() module:[invoice]
    2019-09-29T11:19:09-07:00 DEBUG (7): Export::getData() - logo[http://invoices.master2019.org/templates/invoices/logos/_default_blank_logo.png]
    2019-09-29T11:19:09-07:00 DEBUG (7): Export::getData() - templatePath[templates/invoices/default/template.tpl]
    2019-09-29T11:19:09-07:00 DEBUG (7): Export::showData() - format[pdf]
    2019-09-29T11:19:09-07:00 DEBUG (7): Pdf::generate() - pdfname[Invoice_1.pdf] destination[S]
    2019-09-29T11:19:09-07:00 DEBUG (7): Pdf::generate() - Before WriteHTML
    2019-09-29T11:19:09-07:00 DEBUG (7): Pdf::generate() - Before Output
    2019-09-29T11:19:09-07:00 DEBUG (7): Pdf::generate() - returning Output result
    2019-09-29T11:19:09-07:00 DEBUG (7): email.php - After execute
    2019-09-29T11:19:09-07:00 DEBUG (7): email.php - Before send
    2019-09-29T11:19:09-07:00 DEBUG (7): Email::send() - Before Swift_Mailer send()

    I really don’t know what else to do at this stage and will probably stay with the version that is not using swiftmail as it is working

    in reply to: Debugging email #630
    ppmt
    Participant

    Me again.

    I send an email to one of the host that doesn’t work (migadu) asking them if there was anything they could do to help me and here is what they told me:

    When sending via our SMTP you have to authenticate. Please configure your email client to use plain text authentication over StartTLS.

    Here is the config I am supposed to enter:

    host: smtp.migadu.com
    user: my email
    password: my password
    port: 587
    security: STARTTLS

    I tried the config in SI with TLS and STARTTLS but the result is the same

    Here is again the error I get with it.

    response code 250 but got code "550", with message "550 Authentication required " in /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php:457 
    Stack trace: #0 /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php(341): Swift_Transport_AbstractSmtpTransport->assertResponseCode('550 Authenticat...', Array) #1 /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/EsmtpTransport.php(305): Swift_Transport_AbstractSmtpTransport->executeCommand('MAIL FROM:<phil...', Array, Array, false, NULL) #2 /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php(390): Swift_Transport_EsmtpTransport->executeCommand('DATA\r\n', Array, Array) #3 /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php(497): Swift_Transport_AbstractSmtpTransport->doDataCommand(Array) #4 /var/www/html/vendor/swiftm in /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php on line 457
    in reply to: Debugging email #628
    ppmt
    Participant

    Just a question for you. DO you use your own smtp or a hosted one ?

    I am asking because I have access to a few smtp server and not one of them is working. They all give different errors but bottom line is that I can’t get any of them to work!

    Sorry to be such a pain !

    in reply to: Debugging email #624
    ppmt
    Participant

    I am using the premium byethost and what is strange is that if I use the old version of SI (pre swtiftmailer) it works fine so their config is working.

    I have tried another email provider and with them I get a different error.

    Fatal error: Uncaught Swift_TransportException: Expected response code 250 but got code "550", with message "550 Authentication required " in /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php:457 
    Stack trace: #0 /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php(341): Swift_Transport_AbstractSmtpTransport->assertResponseCode('550 Authenticat...', Array) #1 /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/EsmtpTransport.php(305): Swift_Transport_AbstractSmtpTransport->executeCommand('MAIL FROM:<phil...', Array, Array, false, NULL) #2 /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php(390): Swift_Transport_EsmtpTransport->executeCommand('DATA\r\n', Array, Array) #3 /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php(497): Swift_Transport_AbstractSmtpTransport->doDataCommand(Array) #4 /var/www/html/vendor/swiftm in /var/www/html/vendor/swiftmailer/swiftmailer/lib/classes/Swift/Transport/AbstractSmtpTransport.php on line 457

    so no timeout. The config says to use STARTTLS which I assume is TLS?

    in reply to: Debugging email #617
    ppmt
    Participant

    I have set up the section as per my host. The setting are the same as on the working machine running the old version of SI

    email.host = sv4.byethost4.org
    email.smtp_auth = true
    email.username = myemail@mydomain.com
    email.password = mypassword
    email.smtpport = 290
    email.secure = SSL
    email.ack = false
    email.use_local_sendmail = false

    in reply to: Debugging email #614
    ppmt
    Participant

    On the production machine

    PHP 7.2.19-0ubuntu0.18.04.2 (cli) (built: Aug 12 2019 19:34:28) ( NTS )
    Copyright (c) 1997-2018 The PHP Group
    Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies
        with Zend OPcache v7.2.19-0ubuntu0.18.04.2, Copyright (c) 1999-2018, by Zend Technologies

    and on the test machine

    
    PHP 7.3.9 (cli) (built: Sep 12 2019 10:15:36) ( NTS )
    Copyright (c) 1997-2018 The PHP Group
    Zend Engine v3.3.9, Copyright (c) 1998-2018 Zend Technologies
Viewing 15 posts - 31 through 45 (of 56 total)