coolispaul
asked on
<br> tags and spacer images in HTML emails
Hi
I just wanted to know peoples thoughts on the best way to get pixel perfect spacing between paragraphs etc in html emails.
I have experience of using br and p tags that cause inconsistencies in spacing within different email clients. So, to combat this i have been using spacer images. Some people say this is a bad idea - is this true and if so any advise how spacing should be tackled?
Cheers
I just wanted to know peoples thoughts on the best way to get pixel perfect spacing between paragraphs etc in html emails.
I have experience of using br and p tags that cause inconsistencies in spacing within different email clients. So, to combat this i have been using spacer images. Some people say this is a bad idea - is this true and if so any advise how spacing should be tackled?
Cheers
why don't you use the css div combination?
You can use CSS styles to precisely position each element.
If you're just looking to adjust spacing, something like
If you're just looking to adjust spacing, something like
<br/><span style="line-height:___px;"> <br/></span>
might help you get around the images issue.
Always use CSS for layout. You should never use images or <br /> for spacing. Many people have images turned off in emails, so not only is it bad practice, it would also blow your layout.
To set the spacing below paragraphs simply add a margin-bottom rule to your P tags in CSS.
p { margin-bottom: 25px; }
To set the spacing below paragraphs simply add a margin-bottom rule to your P tags in CSS.
p { margin-bottom: 25px; }
ASKER
i tried this but i only seem to get success by using spacer images for all clients
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.