.htaccess中的404错误

I am new to .htaccess and I want apply .htaccess rule to tags page. The actual page which I am using for tags is tagsearch. Here is my rule

RewriteRule tags/([a-z|A-Z|0-9]+)/$ tagsearch.php?tag=$1 

Please advise.

In regular expression character sets, | is not an "or" symbol, but the literal character |.

Are you maybe missing the initial slash / in the target URL, and want to make the trailing slash optional?

Try this:

RewriteRule ^/tags/([a-zA-Z0-9]+)/?$ /tagsearch.php?tag=$1

Try to enable logging. There is a "RewriteLog" statement for debugging rewrite issues.