api/123/ api/abc/  这两个直接匹配嘛 这样其他路径就不会匹配了 才符合你的要求...

解决方案 »

  1.   

    RewriteRule ^api/(.*)/\?(.*)$  api/index.php?c=$1&$2 [QSA,L]加上 [QSA,L]看看行不?
      

  2.   


    这样就可以了。<IfModule mod_rewrite.c>
    RewriteEngine OnRewriteRule ^api/(.*)/$ api/index.php?c=$1 [QSA,L]
    RewriteRule ^api/(.*)/(.*)$ api/index.php?c=$1%{QUERY_STRING} [L]</IfModule>