Why not just install an Apache server on your computer and test
the site locally?
I have not worked on an IIS server so far, so I can't help you
much with that. But as for mod_rewrite, you can always pass the
language variable to your PHP script with a RewriteRule in the
.htaccess file like:
RewriteRule ([a-z]{2})/(.*) /index.php?lang=$1&path=$2
This will internally redirect (as in it won't be visible to the
user - the URL remains intact) requests like
http://example.com/en/Haruhi to
http://example.com/index.php?lang=en&path=Haruhi.
You may need to switch on the RewriteEngine with the line below
prior to any RewriteRule statement if it is not by default.
RewriteEngine On
To support multiple langauges, you would still have to either
maintain a file or use a database table to store the text for each
language being used. The translated text can be inserted into the
page via defined constants which is similar to what is done in
osCommerce. Like:
require_once $lang . '_constants.php';
<h2><?=TOPIC_TITLE?></h2>
<p><?=TOPIC_TEXT?></p>
Then in en_constants.php, you may have:
define('TOPIC_TITLE', 'Hello World!');
define('TOPIC_TEXT', 'Bla Bla Bla');
And in cn_constants.php, it may be :
define('TOPIC_TITLE', '哈喽, 世界!');
define('TOPIC_TEXT', '卟啦 卟啦 卟啦');
Or you can choose to store them all in a database table and pull
them out in a similar fashion. Either way, please remember to
sanitize all input data (eg. the language variable).
If you want to pass the stuffid in a "cleaner" way, like how
sgForums pass the forum ID and topic ID in the URL, you can always
turn to, once again, mod_rewrite. You can either modify the above
RewriteRule and the script to suit this purpose, or, if you have
already coded the getstuff.php page and everything is pretty much
rigid, you can try adding the below rule on top of the above
one.
RewriteRule ([a-z]{2})/getstuff/([0-9]+)/?
/getstuff.php?lang=$1&stuffid=$2 [L]
So, if the user looks for a page like
http://example.com/en/getstuff/1234, the request will be internally
redirected to
http://example.com/getstuff.php?lang=en&stuffid=1234.