无法使用多个条件重写网址

i need following url to be changed as

http://example.com/Automobile/automotive_listing_subcategory?id=1&title=car-suv also need to rewrite urls such as: http://example.com/Automobile/automotive_listing_category?aid=1&title=car-suv

etc. these all pages under same folder. i had the following code.first one works.but if try to rewrite according to second condition it doesnt work. Anybody please help me.Am not an expert in this area. please correct me if there is any errors.

Options +FollowSymLinks -MultiViews RewriteEngine On RewriteBase /Automobile/

RewriteCond %{THE_REQUEST} ^GET\s([^.]+)\.php\s [NC]
RewriteRule ^ %1 [R,L]
RewriteCond %{THE_REQUEST} ^GET\s([^.]+)\.php\?id=([^&\s]+)\&title=    ([^&\s]+) [NC]
RewriteRule ^ %1/%2/%3? [R,L]
RewriteCond %{REQUEST_FILENAME} !-d 
RewriteCond %{REQUEST_FILENAME}\.php -f 
RewriteRule ^(.+?)/([^/]+)/?$ $1.php?id=$2&title=$3[QSA,L]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}.php -f
RewriteCond %{QUERY_STRING} ^$
RewriteRule ^(.*?)/?$ $1.php [L]
RewriteCond %{THE_REQUEST} ^GET\s([^.]+)\.php\?aid=([^&]+)&title=([^&\s]+) [NC]
RewriteRule ^ %1/%2/%3? [R,L]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}.php -f
RewriteRule ^(.+?)/([^/]+)(/[^/]+)?/?$ $1.php?aid=$2 [L,QSA]

you can read https://www.addedbytes.com/articles/for-beginners/url-rewriting-for-beginners/ and what you need are regular expressions (regexes)

regexes are are chapter for themselves and very tricky to understand sometimes they can also be used with linux commands like grep, sed,... https://en.wikipedia.org/wiki/Regular_expression

the Apache server has a (url) rewrite engine: http://httpd.apache.org/docs/2.0/misc/rewriteguide.html