the situation : The site was previusly created on Coldfusion and it was move to PHP
now we have links like index.cfm?module=mainpage,
The question : how can i retrive the url data after the "?"
?module=mainpage and make work with index.php?module=mainpage
thanks
old Coldfusion Links
Moderator: General Moderators
- evilmonkey
- Forum Regular
- Posts: 823
- Joined: Sun Oct 06, 2002 1:24 pm
- Location: Toronto, Canada
If you're not using coldfusion anymore, you can make your webserver make PHP handle the .cfm extension as opposed to making coldfusion handle it. Otherwise, you'd have to make a CFM script that would forward all those variables to PHP, as in redirect it to a PHP page. No idea how you'd do that, I don't know cfm.
In PHP the query string parameters are parsed into the $_GET superglobal.
In your script you would get at them like
Is that what you were asking?
In your script you would get at them like
Code: Select all
$page = $_GET["module"];
// $page would equal "mainpage" in your example URL now