Please help me, need help getting rid on index.php

Discussion in 'Site & Server Administration' started by jakubsnm, Jul 25, 2009.

  1. #1
    I'm using this code to redirect all index files to root

    RewriteRule ^index.(.*)?$ http://www.mysite.com/  [r=301]
    Code (markup):
    Unfortunately every link from linking websites use the following convention "http://mysite.com" which produces "http://www.mysite.com/index.php?" on my end. With my redirect the links end up as "http://www.mysite.com/?" with the question mark following through.

    How do i get rid of this damn question mark???:mad:???

    My entire .htaccess file is below

    
    Options +FollowSymLinks
    RewriteEngine On
    
    RewriteRule (.+)\.ht$ shop.php?name=$1 [L]  
    RewriteRule (.+)\.html$ auction_details.php?name=$1 [L]  
    RewriteRule (.+)\.cfm$ categories.php?parent_id=$1 [L]
    RewriteRule ^(.*),(.*)$ $2.php?rewrite_params=$1&page_url=$2
    
    RewriteRule ^index.(.*)?$ http://www.mysite.com/  [r=301]
    
    RewriteCond %{QUERY_STRING} base64_encode.*(.*) [OR] 
    RewriteCond %{QUERY_STRING} (<|%3C).*script.*(>|%3E) [NC,OR] 
    RewriteCond %{QUERY_STRING} GLOBALS(=|[|%[0-9A-Z]{0,2}) [OR] 
    RewriteCond %{QUERY_STRING} _REQUEST(=|[|%[0-9A-Z]{0,2}) 
    RewriteRule ^(.*)$ index.php [F,L]
    Code (markup):

     
    jakubsnm, Jul 25, 2009 IP