Ugent halp required

Discussion in 'PHP' started by hallianonline, Feb 5, 2012.

  1. #1
    I have a php form which contains an attribute: action="results.php"
    I want to hide the php extension from results.php to results?showresults or /?results

    and the result page contains the link to go back to index.php and I want to change hide the index.php to just main folder

    Now my question is
    1. whats thing I have to write in .htaccess file and also in php files
    2. Please give me the step by step solution
     
    hallianonline, Feb 5, 2012 IP
  2. SingaHost

    SingaHost Guest

    Messages:
    30
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    can you try

    RewriteEngine on
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_FILENAME}\.php -f
    RewriteRule ^(.*)$ $1.php
     
    SingaHost, Feb 5, 2012 IP