getCartDetailHtmlRows()

Nov 5, 2009 at 11:14 AM
Edited Nov 5, 2009 at 11:20 AM

Hi

Currently one can't control the style of CartDetailsHTML within and HTML email.

So to be "email-html-safe", if you get something like that, I've formatted the order.email in such a manner < td>....< font size="2" face="Tahoma,Arial">Description< /font>....< /td>

but when getCartDetailHtmlRows() generate the html. it is just <td>theValue</td>.
For web page purposes, it is easy to control with css because one can just give the table a class name in your template (ie. tableX) and the create a css for .tableX td {font-size:11px; etc.}

Email, it is different... you have to use very safe methods to make it compliant with a variety of email readers, and using the < font> tag seems the must compatible method.

Now I have this very nice looking order and email being sent to the user, but when it gets to the OrderDetails rows, it shows this big standard times roman fonts.|
Ok, its not urgent, will live with it (i know I can recompile the source and get my own version), but it is something to consider. creating a template called maybe detailrowfontwrapper.template  with something like this inside the template <whaterverYouWant property="blabla">[RowValue]</whaterverYouWant>

 I'm trying to use a css style definition in the top of the orderemailtemplate, but as far as I could find out, emails must use html3.2 standards to be safe,

Regards

Guss

Coordinator
Nov 5, 2009 at 11:32 AM

hmm... yes you're quite right there Guss.

I've been putting "body table td{}" styles in my template header and have just now checked and found the delivered email has the same issue. I'll play with it some more tomorrow... seems like it should be possible to style it... but having the ability to template it with a font tag would certainly be more bulletproof.

Let's see what Dave thinks :)

Rob

Nov 5, 2009 at 12:21 PM

Adding this < style type="text/css">.formatfonts td {font-family:Tahoma; font-size:10pt;}</ style>  even before my first < p > tag worked for Outlook 2007! and offcourse yu have to put class="formatfonts" in the applicable table.

I think this is limited support though. gmail and hotmail and those readers will maybe laugh at my css declaration in the top of the message.
What I do know, that for html email, you put the styles tag inside the body> and not like web pages in the head>

I'm struggling to get a good html email editor or html newsletter editor - trying something called chimpMonkey now to help me stick with html3.2 inline styles.
I've also picked up from the net, that using < font tags is VERY SAFE / compatible in all readers...so at least that is the write track.

Coordinator
Nov 5, 2009 at 5:48 PM

Yes I agree, a template would be ideal for the detail rows.  The original method was a quick fix so I could continue development on more important things.  But like everytime you do something like that it has a habit of become the way it's done.

@Rob, Maybe you should add this one to your project wish list, for when we review what we can fit into the next version.

Dave.

Coordinator
Nov 5, 2009 at 8:25 PM

Yep, done... on the list