.htaccess script urgently needed $10 bounty (I'll shout you a beer!)

Discussion in 'Programming' started by ROOFIS, Mar 24, 2010.

  1. #1
    Hey there DP fans I need a .htaccess code to redirect .asp to root,

    require :
    http://www.example.com/index.asp
    http://www.example.com/news.asp?no=104
    http://www.example.com/news.asp?no=109
    http://www.example.com/library_list2.asp?no=24
    http://www.example.com/features.asp?no=70
    http://www.example.com/features.asp?no=117
    http://www.example.com/ct.html

    all need to be redirected to http://example.com/

    also if one can integrate /index.php to root in the same code I will be most grateful
    here's my current .htaccess for the php redirect,

    Options +FollowSymLinks
    DirectoryIndex index.php
     
    RewriteEngine On
    RewriteBase /
    RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /index\.php\ HTTP/
    RewriteRule ^index\.php$ http://example.com/ [R=301,L]
     
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    Code (markup):


    also if possible one could code a wild card
    entry for the (eg) http://www.example.com/news.asp?no=109 so that every news no=1 to 99999 can point to root this would be a bonus. (this world include library_list2 features wild card coding for their pages as well.) or just the no=x to redirect to root

    an example of this would be typing the following random urls into an address bar
    http://www.example.com/news.asp?no=1
    http://www.example.com/news.asp?no=3487
    http://www.example.com/news.asp?no=10989075
    http://www.example.com/news.asp?no=7

    http://www.example.com/features.asp?no=1
    http://www.example.com/features.asp?no=3487
    http://www.example.com/features.asp?no=10989075
    http://www.example.com/features.asp?no=7

    would all just redirect to http://example.com/ :D

    Please PM me this (not posting here) and I'll upload it to test,
    I'll drop you $10 in your paypal account for the effort, cheers! :cool:





    ROOFIS
     
    ROOFIS, Mar 24, 2010 IP