The SitePoint Forums have moved.

You can now find them here.
This forum is now closed to new posts, but you can browse existing content.
You can find out more information about the move and how to open a new account (if necessary) here.
If you get stuck you can get support by emailing forums@sitepoint.com

If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

Dropdown Box to Change Skin (need help!)

Hi, I currently have a dropdown box on my site http://www.horrorexpress.com that I use to change skins. I basically attach the skin variable (it's a PHP site) to the end of the URL manually (in what now seems a very ugly way).
I've been doing it this way for months, but now I'm switching to SE Friendly URL's this way will no longer be possible. Also it will help to clear up pages in my Search Engine results.

So basically I guess I want to use Javascript to POST the variable (skin name) I need sending, so that it doesn't change the URL or Page?

I know next to nothing about Javascript, so I really would appreciate any help from someone who does.
Thanks.

Actually I do use cookies Mark.
How I've been doing it is checking for "setskin=skinname" in the query string, if it's there set the cookies.
But like I said I want to do it without attaching anything to the query string...http://www.mugglenet.com is a site that does it by sending you back to the same page (which I do) but without adding any query string (which I can't).

No-one have experience of this? I'm really desperate to get it sorted, especially for when I decide to go SE Friendly with mod_rewritten URLs.
(Add: actually they did, I've just noticed they've changed it)

WOW.
I don't know what to say Aska, that is awesome. EXACTLY what I was looking for. And I wouldn't have figured it out in a million years without learning JavaScript (and I'm trying to put all of my energies into PHP and OOP atm).

You have saved me a headache. And coded something perfectly that my site has needed sorting for *months*.
THANK YOU SO MUCH!

(I might actually invest some time in learning JavaScript starting with the above code. Elegant solutions like that are exactly why I tried (and failed) to learn it previously)

WOW.
I don't know what to say Aska, that is awesome. EXACTLY what I was looking for. And I wouldn't have figured it out in a million years without learning JavaScript (and I'm trying to put all of my energies into PHP and OOP atm).

You have saved me a headache. And coded something perfectly that my site has needed sorting for *months*.
THANK YOU SO MUCH!

(I might actually invest some time in learning JavaScript starting with the above code. Elegant solutions like that are exactly why I tried (and failed) to learn it previously)

Glad to hear that John. I kind of started out the same way -- I didn't know much JavaScript (just enough to get by) before I learned PHP.

Thanks Aska, I'll check them out for sure.
[I bought SAMS 'JS in 21 days' book last Christmas, but looking through it I just didn't find anything in it that I wanted to do, for my site. I think it's often best to use websites to find out if you want to invest anymore time and money in learning it. ]

I sure could use a working knowledge of JS, at minimum.
So many languages. So little time.