1

I checked it in IE 11.0.9600.16518 and it is alright for the times I tested in it.

But in IE 11.0.9600.16521, few times (1 of about 30 times) it shows as

enter image description here

The red square is * (for mandatory sign) and other 3 squares are just non-breaking space (&nbsp). The html code when I inspect the drop down list

enter image description here

The all options of drop down are having 4 digits, but when this problem occurs, some options from top show only 3 digits.

Any idea?
Thanks in advance.

Edit : The code I used-

    <select name="sfccode" id="sfccode" style="width:98px; text-align:left" class="TextArea2" onChange="force_value_change(this)">
<?php
echo '<option value="">------Select-------</option>';
while($row=$database->database_fetch_assoc($codes))
{
    echo '<option value='.$row['Code'];
            if(!empty($code_force) && $code_force==$row['Code']) 
            echo ' selected="selected"';
    echo '>'.$row['Code'].'</option>';
}

?>

Code generated is

    <SELECT name=sfccode class=TextArea2 id=sfccode style="WIDTH: 98px; TEXT-ALIGN: left" onchange=force_value_change(this)>�<OPTION value="" selected>�------Select------</OPTION><OPTION value=0111>�011</OPTION><OPTION value=0112>�011</OPTION><OPTION value=0115>�011</OPTION><OPTION value=0116>�011</OPTION><OPTION value=0119>�011</OPTION><OPTION value=0131>�013</OPTION><OPTION value=0132>�013</OPTION><OPTION value=0133>�013</OPTION><OPTION value=0134>�013</OPTION><OPTION value=0139>�013</OPTION><OPTION value=0161>�016</OPTION><OPTION value=0171>�017</OPTION><OPTION value=0172>�017</OPTION><OPTION value=0173>�017</OPTION><OPTION value=0174>�017</OPTION><OPTION value=0175>�017</OPTION><OPTION value=0179>�017</OPTION><OPTION value=0181>�018</OPTION><OPTION value=0182>�018</OPTION><OPTION value=0191>�019</OPTION><OPTION value=0211>�021</OPTION><OPTION value=0212>�021</OPTION><OPTION value=0213>�021</OPTION><OPTION value=0214>�021</OPTION><OPTION value=0219>�021</OPTION><OPTION value=0241>�024</OPTION>.......
Aditya Vijay
  • 231
  • 2
  • 13
  • Add a JSFiddle or at least a link to a demo. – René Roth Mar 31 '14 at 08:04
  • @RenéRoth can't create the fiddle as options are loaded dynamically in thousands. – Aditya Vijay Mar 31 '14 at 08:29
  • Without any code that generates the HTML, even without the generated HTML as text (where characters could be identified), this problem can hardly be solved. – Jukka K. Korpela Mar 31 '14 at 08:38
  • @JukkaK.Korpela : I edited the question with the code. – Aditya Vijay Mar 31 '14 at 09:37
  • Check for encoding mismatchs between your db and the php output. What's the output of "use YOUR_DB_NAME; show variables like '%character%';" – Riccardo Galli Mar 31 '14 at 09:43
  • @RiccardoGalli: show variables like '%character%'; gives the same output between db and php output and use MY_DB gives 1 as php output. don't think its db issue, as &nbsp and * also getting printed as unsupported in browser. – Aditya Vijay Mar 31 '14 at 10:00
  • 1
    The “�” symbols in generated code are U+FFFD REPLACEMENT CHARACTER. If they come from copy and paste from actual code, they indicate a character level data error, quite possibly an encoding issue. Are you using UTF-8 throughout or something else? But if the problem really happens (sometimes) when you have just ` ` in code, then this sounds like a broken browser instance (or maybe broken font). – Jukka K. Korpela Mar 31 '14 at 10:17
  • are you in quirksmode? – Riccardo Galli Mar 31 '14 at 10:17
  • @JukkaK.Korpela : yes I am using UTF-8 as in header I used- Yes sometimes &nbsp and asterisk rendering as square in IE 11. So what can be the solution for this? – Aditya Vijay Mar 31 '14 at 10:32
  • @RiccardoGalli: Sorry but whats that? I think the setting we can do in IE for some backward compatibility testing like changing Document mode etc, but I am not using it. – Aditya Vijay Mar 31 '14 at 10:36
  • There’s little hope of finding a solution unless you can get information on the conditions under which the problem appears. If it appears even with a simple ` ` (note that the semicolon may be significant), maybe you should create a minimal document with basically ` ` only and see whether 1 of about 30 times it gets rendered as a box. – Jukka K. Korpela Mar 31 '14 at 10:36
  • @JukkaK.Korpela : Yes you are right, but I don't think that is going to be happened, because one asterisk in the page is rendered properly, but another one is not. – Aditya Vijay Mar 31 '14 at 10:39
  • @AdityaVijay quirksmode is a special rendering mode of the browsers that is triggered by malformed html, and may produce unexpected behaviours on your page. See http://stackoverflow.com/questions/627097/how-to-tell-if-a-browser-is-in-quirks-mode to see how to check if you are in quirks mode (you shouldn't, you should be in "standard mode"). – Riccardo Galli Mar 31 '14 at 10:57
  • @RiccardoGalli I was in standard mode. Somewhere I got to know that creating options separated with \n can change something. – Aditya Vijay Apr 01 '14 at 12:53

0 Answers0