Drop-down menu question

I am using a drop-down menu so a user can select a language for the page to be displayed in.
In my select options it is currently like this:

        <select name="langChoice" onchange="location = this.options[this.selectedIndex].value;">
            <option>Select language...</option>
            <option value="http://localhost:100/#session.pageName#?langChoice=100">English</option>
            <option value="http://localhost:100/#session.pageName#?langChoice=101">German</option>
            <option value="http://localhost:100/#session.pageName#?langChoice=102">Spanish</option>
        </select>

Open in new window


This reloads the page using the langChoice   variable but it ends up like this:
http://domain/pagename?langchoice= 101

I need it to just reload the page using the langChoice value but not show the:
?langChoice=101

Any ideas?



-
LVL 2
WebStalkersAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

WebStalkersAuthor Commented:
The other thing I just thought of is having the select value go to a redirect page that resets the session var, makes it hidden and forward back to the originating page.
Ryan ChongBusiness Systems Analyst , ex-Senior Application EngineerCommented:
you can change the form behaviour so that it posted to a server side page instead of doing a javascript client side redirection so that in your server side page, you can either set the session variable you want and doing the server side redirection /forward back to the originating page as what you want.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
WebStalkersAuthor Commented:
Thanks for the replay.  i ended up using the redirect solution that I mentioned and have it working now.

Thanks again
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
HTML

From novice to tech pro — start learning today.