Menu

#401 HTML-Mail Templates

Someday
open
Stefan
mail (24)
mail
5
2014-06-15
2011-02-23
Anonymous
No

Es wäre schön, wenn man eine Template-Datei hätte, in der man die Optik für HTML-Mails festlegen kann. Das Mail-Modul könnte dann Multipart-mails mit HTML auf Basis dieses Templates und Plain-text Teil versenden.

Discussion

  • Thomas-RCV

    Thomas-RCV - 2012-10-22
    • module: --> mail
     
  • Stefan

    Stefan - 2014-05-26
    • assigned_to: Stefan
     
  • Stefan

    Stefan - 2014-05-26

    this should be done in 3 steps:

    1.) greate a default template
    2.) use default template
    3.) possibility to change template online (maybe different templates)

    my idea to manage this:

    load the text from the template and exchange some variables in the template with the input and/or values from the database

    $mailbody = str_replace("%body%", "black", "<body text="%body%">");

     
  • Markus Fassbender

    Also have a look at the ecard system. There we use templates already. Maybe some functions can be used or rewritten als common functions.

     
  • Stefan

    Stefan - 2014-06-15

    as a first step and to make it happen asap, i add the function as told in the request...
    in "adm_my_files" add the folder "mail_templates" and there a file "template.html" with the HTML that you want for the Email. where the text from the mail should be, just add the tag "#message#"!

    this is just a fast solution until i have time to put the layout to the database and manage it inside Admidio.

    @Markus: thanks for the information. i will check the ecard system, and also the system mails... maybe we can put all this together to one system

     

Log in to post a comment.