Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6857555
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T02:02:14+00:00 2026-05-27T02:02:14+00:00

Having no luck removing the index.php file from the url. For example I want

  • 0

Having no luck removing the index.php file from the url.

For example I want to access the ‘welcome’ controller via http://domain.com/welcome

Currently getting a 404 error when attempting too.

However, at the moment I can only access is via http://domain.com/index.php/welcome

I have this currently in my .htaccess file which I got from the CI user guide:

RewriteEngine on
RewriteCond $1 !^(index\.php|images|robots\.txt)
RewriteRule ^(.*)$ /index.php/$1 [L]

I have the .htaccess file located in the directory above the application folder.

directory screenshot

Any help would be great.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T02:02:15+00:00Added an answer on May 27, 2026 at 2:02 am

    I have the following .htaccess

    <IfModule mod_rewrite.c>
        AcceptPathInfo On
    
        RewriteEngine On
    
        ### Canonicalize codeigniter URLs
    
        # If your default controller is something other than
        # "welcome" you should probably change this
        # RewriteRule ^(welcome(/index)?|index(\.php)?)/?$ / [L,R=301]
        # RewriteRule ^(.*)/index/?$ $1 [L,R=301]
    
        # Removes trailing slashes (prevents SEO duplicate content issues)
        RewriteCond %{REQUEST_FILENAME} !-d
        RewriteRule ^(.+)/$ $1 [L,R=301]
    
        # Removes access to the system folder by users.
        # Additionally this will allow you to create a System.php controller,
        # previously this would not have been possible.
        # 'system' can be replaced if you have renamed your system folder.
        RewriteCond %{REQUEST_URI} ^system.*
        RewriteRule ^(.*)$ /index.php?/$1 [L]
    
        # Checks to see if the user is attempting to access a valid file,
        # such as an image or css document, if this isn't true it sends the
        # request to index.php
        RewriteCond %{REQUEST_FILENAME} !-f
        RewriteCond %{REQUEST_FILENAME} !-d
        RewriteRule ^(.*)$ index.php?/$1 [L]
    
    </IfModule>
    
    <IfModule !mod_rewrite.c>
    
        # Without mod_rewrite, route 404's to the front controller
        ErrorDocument 404 /index.php
    
    </IfModule>
    

    Also, please be sure that the AllowOverride directive of your httpd.conf is not set to None, since that would prevent your .htaccess rules to be readed.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to edit login.php for sqlbuddy and not having any luck. I want
I'm new to PHP and I'm having no luck googling for a best practice
Not having much luck getting help from any of you Spring gurus on here.
I'm having little luck finding something useful to me via Googling. Specifically what I'm
I know this isn't hard, but I'm not having any luck. I want to
It sounds like Mozilla is having good luck improving JavaScript performance with TraceMonkey .
I'm interfacing with a payment gateway and not having any luck with Net::SSLeay and
Possibly a silly question, but I'm having no luck finding an answer. Using Visual
I am having the worst luck with this. We bought a template to update
Having been a PHP developer on LAMP servers for quite a while, is there

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.