The posted code still seems to be lacking something, but here's what I think is going on:
1. The invario code, as you already stated, changes ?var=foo&secondVar=bar to ?foo:bar
2. When you explode the query string you get an array with simply [0]=>foo,[1]=>bar.
3. It looks like you need to assume that the first variable is always you "id" so
4. $id=$query[0]
5. This is rather brittle -- you'll have to ensure that the id parameter is always the firsst variable on your query string and its possible that the PHPSESS could get stuck there on occasion. But as long as you're aware of that...
The "better" solution in this situation, does require httaccess (ForceType) to strip the .php from the file and use the URL of the form "domain/scriptname/var1/var2/?trueVariable=foo&secondTrue=bar" that way form generated variables can't interfere with the order dependent pseudo-directory ones. Depending on you hosting provider the ForceType directive may be available, without needing to modify httpd.conf, so this might still be an option.
Converting from ?id=blah to ?blah [56k warning]
Moderator: General Moderators
If you learn to ask a question then maybe you will get the answers that you are looking. (Maybe this is your problem when asking your girlfriend questions too).theda wrote:So please, quit giving me the same WRONG answer. I don't need mod_rewrite to fix my page last modified script. <_< Geeesh and I thought getting answers to questions from my girlfriend was difficult.