Suppose I have a line like this:
rajeshpatel&rid=10&sid=20&mid=30
Then how can I get the value "rid" using php.
"rid"
any help?
You can use parse_str like
parse_str
$str = 'rajeshpatel&rid=10&sid=20&mid=30'; parse_str($str,$result); print_r($result); echo $result['rid'];//10
Or you can use it in another way like
parse_str($str); echo $rid;//10
Fiddle