Welcome Guest, Not a member yet? Register   Sign In
path error
#1

I have just installed codeigniter.  I get to the point where the welcome page is displayed.  My base url is http://www.xyz.com/common/.  When I type http://www.xyz.com/common/ or http://www.xyz.com/common/index.php, I get the welcome screen.  When I type http://www.xyz.com/common/index.php/welcome, I am redirected somewhere else.  What am I doing wrong?  Hope I have provided enough information.
Reply
#2

@joeinatlanta,

Did you follow the installation instructions ( https://www.codeigniter.com/user_guide/i...index.html )? It might be a simple configuration issue.
Reply
#3

(01-30-2018, 10:49 AM)php_rocs Wrote: @joeinatlanta,

Did you follow the installation instructions ( https://www.codeigniter.com/user_guide/i...index.html )?  It might be a simple configuration issue.

Yes, very simple.  the default controller is 'welcome',  my base url is "http://www.xyz.com/common/".  When I enter www.xyz.com/common/ or www.xyz.com/index.php everything works ok.  the problem starts when I put the slash after index.  Theoretically, www.xyz.com/common/ should be the same thing as www.xyz.com/common/index.php/welcome since I have not modified any controllers.  Am I missing something?
Reply
#4

(This post was last modified: 01-30-2018, 11:54 AM by php_rocs.)

@joeinatlanta,

What is the value of $route['default_controller'] in routes.php (location: application->config->routes.php)? It should be 'Welcome'.
Reply
#5

@joeinatlanta,
Where are you directed to by the way? I forgot to ask.
Reply
#6

Yes, to your question of default_controller = Welcome. Let me ask the same question from a different perspective. In any configuration the "/" is used to parse folder information. Until faced with this situation, I have never thought what happens when you parse a file "index.php" and supply a "/" as the first argument. I don't know if there is a setting in my configuration that defines how to resolve it. When i execute http://www.xyz/common/index.php everything works as expected. It's when I add the "/" at the end that my site does not know I'm supplying a program and not a folder.
Reply
#7

Just to close this thread and hopefully help others in the future. The problem was my internet provider (GODADDY). Not sure what is different in their setup, but I was able to correct the problem by adding a question mark. From http://www.xyz.com/common/index.php/welcome, to http://www.xyz.com/common/index.php?/welcome. Thanks for your help.
Reply




Theme © iAndrew 2016 - Forum software by © MyBB