how to remove the index.php from client url?

Discussion in 'Apache' started by skillsboy, Oct 12, 2017.

  1. #1
    Hi, newbie here.

    Using apache2 on ubuntu.

    Just wanted to know how can I access a domain "example.com" and not show the url "example.com/index.php", to omit the file index.php on the client browser url.

    Thanks.
     
    skillsboy, Oct 12, 2017 IP
  2. Arun Kumar Soni

    Arun Kumar Soni Well-Known Member

    Messages:
    274
    Likes Received:
    16
    Best Answers:
    2
    Trophy Points:
    165
    #2
    you would do it with an .htaccess file
     
    Arun Kumar Soni, Oct 12, 2017 IP
  3. skillsboy

    skillsboy Peon

    Messages:
    2
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    1
    #3
    I have tried some things around that file but can't realy find out what's the right sintax to omit the file. Do you know any good tutorial or know it yourself ?
     
    skillsboy, Oct 12, 2017 IP
  4. Arun Kumar Soni

    Arun Kumar Soni Well-Known Member

    Messages:
    274
    Likes Received:
    16
    Best Answers:
    2
    Trophy Points:
    165
    #4
    RewriteEngine on
    Redirect 301 /index.php HOMEPAGEURL

    HOMEPAGEURL
    AT this place u can provide home page url
     
    Arun Kumar Soni, Oct 12, 2017 IP