How to compile a regular expression in htaccess?

Hi, there is code:
RewriteEngine On
RewriteRule ^([a-zA-Z0-9_\-]*)\.png$ image.php?user=$1

It works, but I need two parameters, do this:
RewriteEngine On
RewriteRule ([a-zA-Z0-9_\-])\/([a-zA-Z0-9_\-]*)\.png$ image.php&tanks=$1&user=$2

And the code ceases to function, how to fix?
September 19th 19 at 12:54
1 answer
September 19th 19 at 12:56
Solution
There is no asterisk in the first parameter
Tried, but nothing is impossible - Julian.Lark commented on September 19th 19 at 12:59
: and "^" in the beginning - werner commented on September 19th 19 at 13:02
Also not working - Julian.Lark commented on September 19th 19 at 13:05
: RewriteRule ^([\d\w_\-]+)/([\d\w_\-]+)\.png$ image.php?tanks=$1&user=$2 - werner commented on September 19th 19 at 13:08
another school, php&tanks then the question must be - werner commented on September 19th 19 at 13:11
Thank you! Now everything works! - Julian.Lark commented on September 19th 19 at 13:14

Find more questions by tags htaccessRegular expressions