Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>To fix your website in firefox and IE you can use the below methods.</p> <p><strong>Method 1:</strong> </p> <p>You can use the "if condition" that you have used. You need to mention the version of IE in the if statement. See the code below</p> <pre><code>&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt; &lt;html xmlns="http://www.w3.org/1999/xhtml"&gt; &lt;head&gt; &lt;meta http-equiv="Content-Type" content="text/html; charset=utf-8" /&gt; &lt;title&gt;Browser Detection Example&lt;/title&gt; &lt;style type="text/css"&gt; body{ background:blue} &lt;/style&gt; &lt;!--[if IE 6]&gt; &lt;!-- for ie 6 browser --&gt; &lt;style type="text/css"&gt; body{ background:red} &lt;/style&gt; &lt;![endif]--&gt; &lt;!--[if IE 7]&gt; &lt;!-- for ie 7 browser --&gt; &lt;style type="text/css"&gt; body{ background:red} &lt;/style&gt; &lt;![endif]--&gt; &lt;/head&gt; &lt;body&gt; &lt;/body&gt; &lt;/html&gt; </code></pre> <p><strong>Method 2:</strong></p> <p>You can use the css hack inside the css code itself. No need to use a separate css file. You can code in the same css. See the example below </p> <pre><code>&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt; &lt;html xmlns="http://www.w3.org/1999/xhtml"&gt; &lt;head&gt; &lt;meta http-equiv="Content-Type" content="text/html; charset=utf-8" /&gt; &lt;title&gt;Untitled Document&lt;/title&gt; &lt;style type="text/css"&gt; body{ background:blue; _background:orange;} &lt;/style&gt; &lt;/head&gt; &lt;body&gt; &lt;/body&gt; &lt;/html&gt; </code></pre> <p>Note : prefix "_" before the css code it will get render in ie6...</p> <p>Check out !!!</p> <p>regards, Logesh Paul</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload