Click to See Complete Forum and Search --> : Select not Selecting


llanitedave
12-31-2006, 05:22 PM
Hi, all: I'm working on a family web site, and having two problems which I just can't seem to pin down. I'll address the first in this post.

There are three pages so far. At the top of each page I use the following select box to send the user to individual pages:


<form name = "choosePage" id = "choosePage" action = "post">
<b>Choose a page to view: </b>
<select name = "pageView" id = "pageView" onchange = "redirect(this);">
<option value = "" selected = "selected">Select another page</option>
<option value = "theWait.html">The Wait</option>
<option value = "oasis.html">The Oasis</option>
<option value = "purchase.html">The Purchase</option>
<option value = "finalMove.html">The Last Move</option>
<option value = "ours.html">Making it Ours</option>
<option value = "gallery.html">Photo Gallery</option>
</select>
</form>


The select box is tied to a simple javascript function that eliminates the need for a separate "Go" button.

The code in all three pages is identical, except that the option" of the current page is not listed. No functional differences whatsoever.

However, although the code works fine on the second and third pages, it does not work at all on the "index.html" page. The box doesn't even activate to display the list.

But it's the same code!

I've tried it in both Firefox and Konqueror, with the same result, so it's not just the browser, it's got to be me.

What am I overlooking?

ray326
12-31-2006, 09:54 PM
POST is a method, not an action. Are you saying the select appears on the page but it's disabled?

llanitedave
01-01-2007, 12:42 AM
POST is a method, not an action. Are you saying the select appears on the page but it's disabled?

Oh -- Happy New Year, Ray. And thanks for taking the time from it to answer!

Actually, I originally didn't have any action assignment at all: I put it in there because tidy HTML validator scolded me for not having one. It hasn't made any functional difference. Now it validates, but it still doesn't work!

For your question -- yes.

Below are sections of screenshots of the pages in question from Firefox:
http://www.birdandflower.com/llanitedave/showSelect2.png
http://www.birdandflower.com/llanitedave/showSelect1.png

The first shows the select box activated in one of the secondary pages of the site. As you can see, it displays the list of options, and functions as it should.

The second picture is the same select box, using the same code, from the index.html page. It's not activated, and I can't get it to activate.

llanitedave
01-01-2007, 02:15 PM
I mentioned in my first post that there were two problems I was having, but only describing the first one. Well, it turned out they were both the same problem!

It wasn't the code, it was the CSS. On the same line as the nonfunctional items was a div that contained a "next page" link. I used relative positioning to put it on the line, and on the right side of the page, but didn't give it a "width" assignment. Therefore it gave itself a width of 100%, and blocked access to the controls which were underneath its invisible background.

Once I resized the box to keep it from overlapping the other controls (without changing its appearance), everything worked fine!

Live and learn...