Apache: mod_rewrite: Spcaes & Special Characters in URL not working

I use APACHE: mod_rewrite to define a set of URLs rewriting rules

I want this "                                                                     

/myDIR/walls.php?f=All&of=0&s=NewestAll.html

so i use the following rule

text from (.htaccess)

RewriteEngine  on
RewriteBase    /myDIR/   
RewriteRule ^All\.html$  papers.php?f=All&of=0&s=Newest

now these variables, which are transmitted as f=All of=0 s=Newestthey are used in the OBVIOUSLY query, and one of these variables, that is, it fsometimes has values ​​with spaces and special characters, and I can’t avoid it, because the database is already in -place and all that I I’m rewriting URLs ....

NOW when I try to define a rule like this

I want this "                                                                                                             

/myDIR/walls.php?f=Characters & Supers&of=0&s=NewestCharacters & Supers.html

, , . , , ,

RewriteRule ^Characters%20%26%20Supers\.html$  papers.php?f=Characters%20%26%20Supers&of=0&s=Newest

, , 404 " URL/wallz/Characters Supers.html ."

: ?

: HTML- URL .htaccess

+1
1

. URL- mod_rewrite , Apache URL- . , , , .

, :

RewriteRule ^Characters\ &\ Supers\.html$ papers.php?f=%0&of=0&s=Newest

, , ( ):

RewriteRule "^Characters & Supers\.html$" papers.php?f=%0&of=0&s=Newest

Apache- , . , , URL- mod_rewrite.

+5

All Articles