NedreN
12-29-2005, 05:40 PM
Hello. I'm looking for some help. I'm not really a javascript guy, so I really don't know what I need to do to get this to work. I've searched these forums and google and cannot find the answer to my problems.
So some background information. I'm working on a WHM hosting account managment system, and I have a few pages where there are rather large lists (HTML select lists) of account names that various things are done with the accounts once selected. Since the lists are so large, I have made a "Find Me" box that when a user types a character/string into the html input it "finds" the closest match in the select list and highlights it. That works find though, so that I'm not worried about.
The problem is that I have a little image that when clicked it "unhides" two table cells set to "display: none" with CSS. This works fine in Firefox, but I cannot get it to work in IE. I get the error: "Could not get the display property. Invalid Argument." when I click the image in IE. I know the error pretty much tells me what is wrong in most cases, but I don't understand what I need to do to get it working.
Here is the function I have:
function hider() {
var hidden1 = document.getElementById("hidden1");
var hidden2 = document.getElementById("hidden2");
if (hidden1.style.display == 'none') {
hidden1.style.display = 'table-cell';
hidden2.style.display = 'table-cell';
}
else {
hidden1.style.display = 'none';
hidden2.style.display = 'none';
}
}
The table row I have is:
...
<tr>
<td id="hidden1" name="hidden1" style="display: none;"><span class="bold">Find Me:</span></td>
<td id="hidden2" name="hidden2" style="display: none;"><input size="20" type="text" name="findme" onKeyUp="matchZone();"></td>
</tr>
...
I'm very unsure if how I am going about this is even close to the correct way, so yea, don't laugh at me. :-P
If anyone could give me a few pointers and help me get this sorted out it would be quite nice and I would appreciate it.
Thank you for your time,
-Nedren
So some background information. I'm working on a WHM hosting account managment system, and I have a few pages where there are rather large lists (HTML select lists) of account names that various things are done with the accounts once selected. Since the lists are so large, I have made a "Find Me" box that when a user types a character/string into the html input it "finds" the closest match in the select list and highlights it. That works find though, so that I'm not worried about.
The problem is that I have a little image that when clicked it "unhides" two table cells set to "display: none" with CSS. This works fine in Firefox, but I cannot get it to work in IE. I get the error: "Could not get the display property. Invalid Argument." when I click the image in IE. I know the error pretty much tells me what is wrong in most cases, but I don't understand what I need to do to get it working.
Here is the function I have:
function hider() {
var hidden1 = document.getElementById("hidden1");
var hidden2 = document.getElementById("hidden2");
if (hidden1.style.display == 'none') {
hidden1.style.display = 'table-cell';
hidden2.style.display = 'table-cell';
}
else {
hidden1.style.display = 'none';
hidden2.style.display = 'none';
}
}
The table row I have is:
...
<tr>
<td id="hidden1" name="hidden1" style="display: none;"><span class="bold">Find Me:</span></td>
<td id="hidden2" name="hidden2" style="display: none;"><input size="20" type="text" name="findme" onKeyUp="matchZone();"></td>
</tr>
...
I'm very unsure if how I am going about this is even close to the correct way, so yea, don't laugh at me. :-P
If anyone could give me a few pointers and help me get this sorted out it would be quite nice and I would appreciate it.
Thank you for your time,
-Nedren