I have a URI like this:
I want to get makemoney and after "?" character values. In my .htaccess file write this rule:
RewriteRule ^demo/(.*)?(.*)$ demo.php?utm_campaign=$1&$2 [L,NC]
But only utm_campaign I get in $_GET super globals. What's true regex?
Best How To :
The query string is separate from the request uri. In your case you only want to add a value to it, so you can use the
[QSA] (Query String Append) flag to pass the entire query string with the value you captured from the URI
RewriteRule ^demo/(.*)$ demo.php?utm_campaign=$1 [L,NC,QSA]