Seeing a lot of smarty errors in Drupal log file for mailings using Mosaico template - looks like an error for every message sent so thousands filling log files.

Nothing obvious in Mosaico template but thinking it must be a conflict with use of { } in each case. Smarty logic in the template that I can see.

should smarty be turned off in civicrm.settings.php if using Mosaico?

  • What is the version of Mosaico and flexmailer ext ? Are they on latest? – jitendra - fuzion Feb 14 '19 at 8:31
  • yes, I believe these are current - flexmailer 0.2-alpha5 and mosaico 2.0-beta4.1528762072 – Dave T Feb 14 '19 at 20:30

You can't use Smarty and Mosaico together. Tim Otten presents a long answer why if you want details!

  • OK, good to know. Should there be a warning in system status? Painful error to find after the fact. – Dave T Feb 27 '19 at 19:22
  • Not a bad idea - but to be clear - are you using Smarty logic in Mosaico? Or do you have curly brackets that make Mosaico think you're using Smarty? Since Mosaico users can still send traditional CiviMails, it'd be good to make sure they could use Smarty when doing so. – Jon G - Megaphone Tech Feb 27 '19 at 22:42
  • No Smarty logic to my knowledge in Mosaico maling template - only whatever Mosaico would use in its templates. Agree that it would be too bad to have to disable Smarty for all uses even if not Mosaico. – Dave T Feb 28 '19 at 23:05
  • Hmm - @DaveT are you using the latest version of Mosaico 2.x? I would have assumed that Flexmailer would have prevented these errors. Do you have "View on Website" in use? Is it possible that the Smarty errors appear when someone views a Mosaico mailing on the website? I believe there's an open issue for that. – Jon G - Megaphone Tech Feb 28 '19 at 23:14
  • Hmmm, Hmmm - just updated to most recent (stable) version of Mosaico - 2.0.1556289017 - Initial (very limited) testing does not show smarty errors. Perhaps fixed? – Dave T May 3 '19 at 12:56

I found this: https://github.com/mjwconsult/civicrm-mosaico_smarty I need to upgrade my system to try it out, let me know if it works.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.