A new XSLT utility, “HTML to Email Text” is now available for download. Comments and feedback can be left here but if you discover any issues, please post it on the issue tracker.

This utility has been developed to be used with the Email Newsletters extension. It is based on the HTML To Markdown Text utility.

Website authors may write content using Markdown or even HTML markup. This is why you should not use unformatted textarea datasource output to create email text content. Instead you may use XSLT to build the text content (based on your datasource’s formatted, i.e. HTML, output).


A very simple example page XSLT might look like this:

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"

<xsl:import href="../utilities/html2emailtext.xsl"/>

<xsl:output method="xml"
    indent="yes" />

<xsl:template match="data">
    <xsl:apply-templates select="newsletter/entry[1]"/>

<xsl:template match="newsletter/entry">
    <xsl:value-of select="title"/>
    <xsl:apply-templates select="text" mode="email"/>
This is the signature...



This is a start. But be warned: Creating TEXT pages (and HTML pages alike) suitable for emails is a hassle!

Create an account or sign in to comment.

Symphony • Open Source XSLT CMS

Server Requirements

  • PHP 5.3-5.6 or 7.0-7.3
  • PHP's LibXML module, with the XSLT extension enabled (--with-xsl)
  • MySQL 5.5 or above
  • An Apache or Litespeed webserver
  • Apache's mod_rewrite module or equivalent

Compatible Hosts

Sign in

Login details