My web application is Asp.NET 2.0 and in one page, i'm using HttpWebRequest to load some content into a container page. This works well within Firefox, IE7/8, Safari but it crashes IE6. It hangs or shuts down.
The content page i'm trying to read is called tmp.html and if i call it directly (using IE6) then it seems ok. The html code inside tmp.html is :
<table width="100%" border="0" cellspacing="0" cellpadding="0" style="background-image: url(images/jpg/alt_right_top.png);
background-repeat: no-repeat;">
<tr>
<td align="center" valign="bottom">
<img src="images/jpg/baslik_icindekiler.jpg" style="margin-top: 20px;"></td>
</tr>
</table>
this crashes the browser but if i remove the line : "background-image: url(images/jpg/alt_right_top.png);" then it shows up correctly even if i call it through HttpWebRequest.
example link : http://www.smilevitamin.com/smilevitamin/vitamin.aspx
Any ideas? Is this an Internet Explorer 6 bug?
why don't you use any JavaScript framework that is tested for these kind of things?
Jquery is a good example.
Related
When opening a html mail with its code written for Windows 10 mail client (I assume Outlook 2007 +also) which uses Word engine i can see all images (img tag) or vml language controls rendered properly. But often i see some controls images missing when opening the same e-mail the second time or on resizing windows 10 mail window. Because of this resizing of a loaded e-mail window it doesn't seem have anything to do with some delays in loading elements via Internet, especially that a vml control doesn't use any outside recources. The html mail code is based on tables. Here's an example code with sometimes visible or invisible element:
<table cellpadding="0" cellspacing="0" width="273" border="0" style="padding:0;border-collapse:collapse; border-spacing: 0px;">
<tr>
<td width="273" valign="middle" align="center" bgcolor='#f7941d' style="background: #ffffff">
<!--[if gte mso 12]>
<v:roundrect xmlns:v="urn:schemas-microsoft-com:vml" xmlns:w="urn:schemas-microsoft-com:office:word" href="https://example.com/" style="height:46px;v-text-anchor:middle;width:273px;" arcsize="15%" strokecolor="#f7941d" fillcolor="#f7941d">
<w:anchorlock/>
<center><font size="4" color="white" face="Verdana,sans-serif" style="text-decoration:none;font-size: 20px;line-height: 46px"><b>BUTTON TEXT <font class="greaterthan" style="position: relative;top: -1px;">></font></b></font></center>
</v:roundrect>
<![endif]-->
<font size="5" color="white" face="Verdana,sans-serif" style="text-decoration:none;font-size: 20px;line-height: 46px;mso-hide:all;"><b><font style="display:none;"> </font>BUTTON TEXT <font class="greaterthan" style="position: relative;top: -1px;">></font><font style="display:none;"> </font></b></font>
</td>
</tr>
<tr><td height="30"></td></tr>
</table>
This question seems to be really important to everybody having outlook 2007+ in mind.
Thank you in advance.
Well, this answer can be not enough, but in my case it helped when a VML button got position:relative - i didn't see it display inproperly even once. But for windows 10 mail you cannot use position: relative for non VML elements so what may help somebody to simplify her/his code as much as possible - dissapearing of elements may not be as often (as in my case), using less nested elements might help. This is what i noticed so far. A piece of code can be written from scratch different way also if nothing works.
Well to remember, in some situations using position for vml elements may not position an element as expected. But i had success with a vml button. position:relative;top:1px; this is what i did.
I'm having trouble getting my HTML email template to render properly when it is sent from Mailchimp to Outlook 2007, 2013 and 2016. The thing is, when I upload the HTML directly for testing on Litmus, the email renders fine across all Outlook previews. When I send the test email from Mailchimp to Litmus, the email looks out of proportion in Outlook 2007, 2013 and 2016 (for Win7).
Is Mailchimp doing something with my Outlook-targeting conditional comments, and how can I work around that?
My conditional comments seem to work sometimes to fix the width on some elements of my MC email (you'll see in the screenshots, the textbox is the right size for the top card but not on the second one). But for the life of me, I can't figure out why one works and the other doesn't, I'm writing the same comment for both.
Screenshots:
when Mailchimp sends the email to Outlook (what went wrong)
when the HTML is rendered for Outlook directly (what it's supposed to look like)
Conditional comments:
I've put in Outlook-specific conditional comments like so:
<!--[if (gte mso 9)|(IE)]>
<table align="center" border="0" cellspacing="0" cellpadding="0" width="600">
<tr>
<td align="center" valign="top" width="600">
<![endif]-->
<!--BODY TABLE-->
<table align="center" border="0" cellpadding="0" cellspacing="0" width="100%" style="max-width:600px;">
...
</table>
<!--[if (gte mso 9)|(IE)]>
</td>
</tr>
</table>
<![endif]-->
Thank you for the help! Really appreciate it.
I feel your pain, I've had the same issue for templates I was making for a client. I wanted to make the icons retina proof and let the client upload any image size he'd like. Unfortunately after many many hours debugging en searching the web, I read the following on a MailChimp post:
Outlook doesn’t recognize the HTML that constrains images. This means
that if you use HTML to resize an image uploaded to a campaign or
template, it may display at the original size in Outlook. Be sure to
resize your images before you upload them to MailChimp, or use our
built-in image editor.
source: MailChimp Knowledge Base
I didn't really believe that this could actually be true so I kept trying to constrain the images. I've put fixed width on the img, td, tr, table.. nothing helped.
Sadly I can't really explain what happens, hopefully the link to the MC article gives you a better view on it.
But my best answer is to set a max-width & width to your img and td anyway. And tell your client to resize the images to the allowed size. Setting a max-width and width will also display the #px when hovering over the editable image in your MailChimp editor. I also found out that when you do upload a bigger size, MailChimp throws a lil' warning.
If it may help in any way; see my code below that I used in my templates to make it fluid.
<table mc:repeatable mc:variant="Item with image top and CTA" width="650" cellpadding="0" cellspacing="0" border="0" align="center" class="full-table" style="width:650px;">
<tr>
<td style="padding:30px 20px 40px 20px;" bgcolor="#FFFFFF">
<table width="100%" cellpadding="0" cellspacing="0" border="0">
<tr>
<td style="padding-bottom:15px;max-width:610px;">
<img src="/images/img.jpg" alt="x" style="width:100%; max-width:610px;" width="610" mc:edit="article_image">
</td>
</tr>
</tr>
</table>
</td>
Are you using retina images in your emails? From experience I have found that outlook's, if they are given a big image, they display it at a big size if a specific width is not assigned to the img tag. Below is an example of a code i use for the images in my emails.
<img src="[IMAGE PATH]" width="" height="" style="width:px; height:px;display:block;" border="0">
Also can you post the img tag of the offending element so i can have a look at it better please?
Cheers
I have this form that works fine, however, in my Logo.aspx file, I have 3 logos on the head of the form.
However, the Logos in the asp file pushes the third image to the right.
Is their a way to control the size of the logos in the front end?
This issue only occurs in IE10. But all other version of IE and Chrome, it works fine
Below is what I have tried and it does not work:
<table style="width: 100%">
<tbody>
<tr>
<td align="left" width="10%"><!-- #INCLUDE FILE="scripts\Logo2_C.aspx" --></td>
<td align="right" width="90%"><img src="/images/logos/logo.png" /></td></tr></tbody>
you can use 'inline-block' instead of a table:
<div style="display:inline-block;width:10%;"><!-- #INCLUDE FILE="scripts\Logo2_C.aspx" --></div>
<div style="display:inline-block;width:90%;"><img src="/images/logos/logo.png" /></div>
I have written html code in JSP file and it is for showing icon link. It is successfully running in IE browser but not showing image icon in chrome and Firefox browser and even no adblocker is there in my browsers.
<table border="1" width="90%" class="buttons">
<tr>
<td width="25%">PROJECT
</td>
<td width="25%">
<a href="CrunchifyServlet">
<img height="20px" src="C://Users//Downloads//Start-icon.png">
</a>
</td>
</tr>
</table>
Your image URL points to a resource which ist only accessible for browsers if they have permission to read the file system. Also no one but yourself will have access to this URL.
Better change the absolute URL…
<img height="20px" src="C://Users//Downloads//Start-icon.png">
into a relative one:
<img height="20px" src="./YOUR-PATH-HERE/Start-icon.png">
This also helps you in case you want to copy your files to another server.
Also see https://developer.mozilla.org/en-US/Learn/Common_questions/What_is_a_URL for more information on URLs.
My site is at http://www.eluonpidu.com
The menu images aren't appearing in chrome the first time you visit the page. IE and Firefox work as expected. If I refresh the page, then the images appear for Chrome.
On the the code below you need to add width="100%":
<td id="manuu">
<table cellspacing="0" cellpadding="0" border="0" width="100%">
That should fix your issue.