I have a url with variables in it. The variables are used multiple time and I’ve been told that this will automatically put each value for the variable in a list instead of replacing the value each time. I can’t get this to work though.
I’m assuming that in my php using GET that “variable1” would equal “hello,hello2,hello3”. Instead, it equals “hello3”.
hmmm.. I dont know if that can be done.
But, simple explanation. “variable1” keeps getting replaced by a different value.
Could try this, based on your example:
‘www.url.com/index.php?variable1=’ . value1 . ’,’ . value2 . ’,’ . value3
I have heard that about radio boxes and check boxes not sure if it works if you directly manipulate the URL like that. What do you want the php to do exactly?
I don’t know why somebody told you that they’d get concatenated.
What you are trying to achieve has little to do with PHP really, it depends 99% on what is going on client side. This might happen to be a PHP created page, in which case concatenating would be like:
$variable1 = $_GET['variable1']; $variable1 .= ",part2"; $variable1 .= ",part3"; // etc $url = "http://somedomain.tld/page.php?variable1=" . $variable1;
However, if I am right to assume you are using Flash to do whatever it is to these URLs, apply the same technique to those URLs in Flash…
The part that is driving me nuts is that I swear this worked a few days ago and now it isn’t. I may be losing my mind.
Thanks anyway, everyone.
I spoke with some other coders. They said that .asp concatenates url variables, but php doesn’t read it that way.