URL rewrite requires support from the server! Before Enabling this setting, make sure that the correct settings have been made on the server. For the setting method, see "setting methods under Apache" and "setting methods under IIS" below "!
Configuration method in Apache
CopyCode The Code is as follows: Open the Apache configuration file httpd. conf.
Remove the # loadmodule rewrite_module modules/mod_rewrite before #.
Add the following in httpd. conf:
<Ifmodule mod_rewrite.c>
Rewriteengine on
# Rewritecond % {env: script_url }(? : Index | dispbbs) [-0-9] + \. html
Rewriterule ^ (.*? (? : Index | dispbbs)-([-0-9] +) \. html $ 1.php? _ Is_apache_rewrite = 1 & __ rewrite_arg = $2
</Ifmodule>
To map ASP post URLs to PhP posts, add the following between <ifmodule mod_rewrite.c> and </ifmodule> in step 3:
Rewritemap tolowercase INT: tolower
Rewritecond % {QUERY_STRING }(? : Boardid | PAGE | ID | replyid | star | skin) \=\ D + [Nc]
Rewriterule ^ (.*(? : Index | dispbbs) \. ASP $ 1.php? $ {Tolowercase: % {QUERY_STRING }}&__ is_apache_rewrite = 1
Save httpd. conf and restart Apache.