Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

index.php showing up


Go to End
Reply


9 Posts   2520 Views

Avatar
cumquat

Community Member, 198 Posts

5 May 2013 at 6:08am

Hi there,

Over the last few weeks i have been building a few sites on different servers with 3.1 beta 2 and now beta 3 and i seem to be getting a lot of issues with index.php showing up.
Mod_rewrite is on and my .htaccess file is the standard default one. if i remove index.php from the url the site works perfect showing that mod-rewrite is working yet when i go back to the home page and chose a menu item it puts the index.php back into the link.

Anyone else noticed this or having the same problem?

Mick

Avatar
Bambii7

Community Member, 254 Posts

7 May 2013 at 7:23pm

Are you cconfident mod_rewrite is enabled in Apache not just in the htaccess?
Or make sure .htaccess files are enabled (or preferably have the htaccess content in the sites-enabled config file)

it sounds like this just isn't getting hit in the when apache requests the file
IfModule mod_rewrite.c
RewriteEngine On
RewriteBase '/'

Avatar
Nobrainer Web

Community Member, 137 Posts

8 May 2013 at 5:41am

After removing index.php did you ?flush=all.

I remember having this issue on sites before, but as far as i remember, it worked when removing index.php

Avatar
cumquat

Community Member, 198 Posts

8 May 2013 at 6:27am

Thanks guys,

You know i have never deleted the index.php file on all the sites i have done (over 40)

But yea removing the index.php file fixed my problem...

Thanks for that.

Mick

Avatar
thomas.paulson

Community Member, 84 Posts

1 June 2014 at 12:03am

I had the similar issue, style we not applied, removing the index.php solved my problem.

Thanks everyone

Avatar
kevinstripe

Community Member, 10 Posts

4 June 2014 at 4:35pm

Yes, I had kind of same problem and I also fixed it by removing index.php.

Avatar
bunheng

Community Member, 78 Posts

8 June 2014 at 2:16am

Hi,

I am the same issue, after installing the WAMP server on my machine, I did checked the rewrite module is working, is there any clue to make it work without removing index.php or customize the code?

Thanks

Avatar
Frank108

Community Member, 1 Post

11 November 2014 at 9:37pm

Edited: 11/11/2014 9:37pm

I think that a better solution is that in index.php on line 18, instead:

define('BASE_SCRIPT_URL','index.php/');


remove index.php and it'll look like:

define('BASE_SCRIPT_URL','');

Go to Top