Ok I have another question and I’m a beginner at this.
I have this RewriteRule, it redirects the query correctly but doesn’t allow me to use the other directories:
RewriteRule ^([0-9A-Za-z]+)/?$ /query.php?id=$1 [L]
and now this RewriteRule to skip all these directories but now the rule above needs to be commented out for this to work.
RewriteRule ^(css|js|admin|pages|includes|images)(/|$) - [L]
Can I combine the two? If so, how?
RewriteRules are checked in the order they occur in the file, so if you put thecss|js|admin|pages|includes|imagesrule first, it will match first and stop the rewriting process before the other rule is reached. Just make sure to keep the[L]flag at the end of that rule.