For rewrite rules, OpenLiteSpeed uses the same syntax as Apache's [http://httpd.apache.org/docs/current/mod/mod_rewrite.html mod_rewrite]. Apache rewrite rules can be copied and pasted into OpenLiteSpeed's Rewrite Rules field (WebAdmin > Configuration > Virtual Hosts > your virtual host > Rewrite > Rewrite Rules).
It should be noted, though, that [http://httpd.apache.org/docs/current/mod/mod_rewrite.html#rewriterule Apache mod_rewrite syntax is slightly different when a rewrite rule is in an .htaccess file as opposed to virtual host configuration (in an httpd.conf file)]. OpenLiteSpeed rewrite should be written in this vhost config syntax. If you are copying a set of rewrite rules from an Apache .htaccess file to OpenLiteSpeed, use the following guidelines to edit the rules so they conform to vhost config syntax.
== Conversion Guidelines ==
=== RewriteBase is not supported in virtual host configurations ===
The RewriteBase directive can only be used in .htaccess rewrite rules and thus is not supported in OpenLiteSpeed virtual host configurations. (If you need RewriteBase functionality, it can be used in an OpenLiteSpeed Context, but is usually not necessary, since the URL prefix is stipulated in the Context's [http://www.litespeedtech.com/docs/webserver/config/context#expuri URI] and [http://www.litespeedtech.com/docs/webserver/config/context#location Location] settings.)
=== Add a forward slash at the beginning of the rule pattern ===
<pre>RewriteRule ^/([a-zA-Z0-9_-]+)$ http://m.domain.com/$1/ [R=301,L]</pre>