I have a page that takes a GET variable, q from the URL using the following code:
<?php ob_start(); session_start();
$q=trim($_GET['q']); // this is for security purposes
if (!is_numeric($q)){
header("HTTP/1.0 404 Not Found");
}
?>
The current URL looks like localhost/s/index.php?q=345. I will soon write a .htaccess file that makes the URL look like localhost/345. I was wondering if i could still grab the GET variable (q) using the code above. I’m concerened it wont work because the URL won’t have the typical GET appearance. In the new URL the “GET” variable will look like a folder.
If your
RewriteRulesubstitution string doesn’t contain a?intro then the query string is left unchanged. If it does and you also specify a[qsa]flag then the existing query string will be appended to the new one in your substitution string.