DaniWeb IT Discussion Community

DaniWeb IT Discussion Community (http://www.daniweb.com/forums/)
-   JavaScript / DHTML / AJAX (http://www.daniweb.com/forums/forum117.html)
-   -   problem with drop down SELECT box. (http://www.daniweb.com/forums/thread112308.html)

nava Mar 5th, 2008 8:37 am
problem with drop down SELECT box.
 
Hi

Hope is the correct forum, let me know if I should move it.

For work I need to use an internal website the problem I have is that since I upgraded IE7 I cannot see it correctly, looking at the source I can see the script below

<label for="supGrpSrch">Search on:&nbsp;</label></td><td><select name="supGrpSrch" onchange="javascript:setOrigImage(document.forms[0].descImg1)" ><option value="0" label="supGrpSrch0" >Group</option><option value="1" label="supGrpSrch1" >Group description</option><option value="2" label="supGrpSrch2" >Supplier number</option></select>

So I think I should see the Value not the label value.

Below is what I can see in IE7



Below what I should see taken from Firefox.



Thanks in advance.

ShawnCplus Mar 5th, 2008 11:56 am
Re: problem with drop down SELECT box.
 
In Internet Explorer 7, the 'label' property is equivalent to the innerText property in Firefox. So Firefox ignores the label property and uses innerText (Group) whereas IE sees the label property(supGrpSrch0) and overrides the innerText.

nava Mar 5th, 2008 12:27 pm
Re: problem with drop down SELECT box.
 
HI

thanks for that,

Is there a way to fix that in IE7, other than editing the page that I know won't be done, maybe with a plug-in or any other way.

Thanks

ShawnCplus Mar 5th, 2008 12:31 pm
Re: problem with drop down SELECT box.
 
Yeah, take out the label attribute. It's not serving any purpose in firefox or IE


All times are GMT -4. The time now is 2:48 am.

Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC