SOLVED

DOCTYPE advice

Go to solution
Frank_Breen2
Level 10

DOCTYPE advice

I'm updating our email templates to make them all consistent and have just converted to Email 2.0, Email on Acid suggested the following declaration:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml"

xmlns:v="urn:schemas-microsoft-com:vml"

xmlns:o="urn:schemas-microsoft-com:office:office">

But when I go into my 1.0 template to re-edit the code, Marketo converts it to this:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"><html>

I'm not sure if it's a bug, as when I clone the template and edit it, it keeps my original declaration. Any advice?

Tags (1)
1 ACCEPTED SOLUTION

Accepted Solutions
Casey_Grimes
Level 10

Re: DOCTYPE advice

With respect to Jay, that recommendation to still use XHTML 1.0 transitional is 5 years old. Nowadays, I tend to agree with Rémi Parmentier that HTML5 makes sense to declare in most day-to-day scenarios; very few clients (all of which are legacy) will require some form of HTML4. It's also worth doing a quick check to see if transitioning your code from XHTML 1.0 to HTML5 causes any breaks due to deprecated methods; generally there are graceful failings due to backwards compatibility, but the two standards do have little odd differences between them.

As far as the reversion goes, I'm fairly sure it's related to the behavior seen in ​.

View solution in original post

2 REPLIES 2
Jay_Jiang
Level 10

Re: DOCTYPE advice

Go with xhtml 1.0 transitional, explanation here: A guide to doctype usage in HTML emails | Campaign Monitor

The Marketo email editor 1.0 starting template must be like 10 years old

Casey_Grimes
Level 10

Re: DOCTYPE advice

With respect to Jay, that recommendation to still use XHTML 1.0 transitional is 5 years old. Nowadays, I tend to agree with Rémi Parmentier that HTML5 makes sense to declare in most day-to-day scenarios; very few clients (all of which are legacy) will require some form of HTML4. It's also worth doing a quick check to see if transitioning your code from XHTML 1.0 to HTML5 causes any breaks due to deprecated methods; generally there are graceful failings due to backwards compatibility, but the two standards do have little odd differences between them.

As far as the reversion goes, I'm fairly sure it's related to the behavior seen in ​.