Go Back   Forum Care Forums > Development Reference Area > Php Development

Reply
 
LinkBack Thread Tools Display Modes
[PHP] $_GET strings seperation
Old
  (#1)
Navid Yar
Guest
 
Posts: n/a
Default [PHP] $_GET strings seperation - 06-02-2007, 08:55 PM

Hello Everyone,

I have a problem with GET strings. I use
$_SERVER["REDIRECT_QUERY_STRING"] to get the value-pairs in the URL.
The problem is that there is a cID variable that keeps appending itself
to the string continuously everytime someone clicks on a different
category link on the website. For example, instead of this:

http://www.someexample.com/admin/ind...omevar2=value2

it keeps appending another cID to it everytime it goes to a different
link, like this:

http://www.someexample.com/admin/ind...omevar2=value2

I know that this is happening because I'm appending it with the dot (.)
but is there a way to just inject a single cID and still have the rest
of the value-pairs available? Something built into PHP, maybe a different
predefined variable I don't know about? Or, do I have to make a
complex function to separate each out and then put it back together
again like humpty dumpty? Is there an easier way to do this and still
have a single cID variable in the GET string? Thanks in advance.
   
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Re: [PHP] $_GET strings seperation
Old
  (#2)
Tijnema
Guest
 
Posts: n/a
Default Re: [PHP] $_GET strings seperation - 06-02-2007, 08:55 PM

On 5/26/07, Navid Yar <EMAIL REMOVED> wrote:
> Hello Everyone,
>
> I have a problem with GET strings. I use
> $_SERVER["REDIRECT_QUERY_STRING"] to get the value-pairs in the URL.
> The problem is that there is a cID variable that keeps appending itself
> to the string continuously everytime someone clicks on a different
> category link on the website. For example, instead of this:
>
> http://www.someexample.com/admin/ind...omevar2=value2
>
> it keeps appending another cID to it everytime it goes to a different
> link, like this:
>
> http://www.someexample.com/admin/ind...omevar2=value2
>
> I know that this is happening because I'm appending it with the dot (.)
> but is there a way to just inject a single cID and still have the rest
> of the value-pairs available? Something built into PHP, maybe a different
> predefined variable I don't know about? Or, do I have to make a
> complex function to separate each out and then put it back together
> again like humpty dumpty? Is there an easier way to do this and still
> have a single cID variable in the GET string? Thanks in advance.


Show us what you have so far, so that we can think about a fix.
*note that you don't need to place all code here, but only the relevant part.

Tijnema
   
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On





Contact Us - Forum Care Forums - Archive - Top