Welcome Guest, Not a member yet? Register   Sign In
No input file specified. Godaddy
#1

Help! After days and trying every combination of .htaccess and config.php I could find, I still have "No input file specified".



CodeIgniter will bring up the welcome screen as long as I don't try to call a controller, but fails on any one I try.

such as; http://mysite.org/CodeIgniter/index.php/main or http://mysite.org/CodeIgniter/main with .htaccess 



Site is Godaddy shared Economy Linux hosting (Yes I wish it was a different host)

with Wordpress and Wordfence installed in the root.



CodeIgniter is installed in: /CodeIgniter

PHP Version 5.6.27



The problem seems to be the way Godaddy handles paths, but I'm not smart enough to figure it out.

These entries are in the error log:

DEBUG - 2017-12-08 10:20:59 --> No URI present. Default controller set.

INFO - 2017-12-08 10:20:59 --> File loaded: /home/content/50/8634350/html/CodeIgniter/application/views/welcome_message.php



Here are some server varibles, both ran from directory /test:

Working site:

_SERVER['DOCUMENT_ROOT']: /home1/raymayna/public_html

_SERVER['SUBDOMAIN_DOCUMENT_ROOT']: 

_SERVER['HTTP_HOST']: mysite.com

_SERVER['SERVER_NAME']: mysite.com

Current Path: /home1/raymayna/public_html/test



Non working Godaddy site:

_SERVER['DOCUMENT_ROOT']: /var/chroot/home/content/50/8634350/html

_SERVER['SUBDOMAIN_DOCUMENT_ROOT']: /var/chroot/home/content/50/8634350/html

_SERVER['HTTP_HOST']: mysite.org

_SERVER['SERVER_NAME']: mysite.org

Current Path: /home/content/50/8634350/html/test



Note the differences in DOCUMENT_ROOT and Current path on the Godaddy site.



Here is my CodeIgniter configuration:

config.php

$config['base_url'] = 'http://mysite.org/CodeIgniter/';

$config['uri_protocol'] = 'REQUEST_URI';

Also tried,

$config['uri_protocol'] = 'QUERY_STRING';





$config['index_page'] = 'index.php';

with no .htaccess in /CodeIgniter



Also tried,

$config['index_page'] = '';

with the following .htaccess in /CodeIgniter;

.htaccess

RewriteEngine On

RewriteCond %{REQUEST_URI} ^/system.*

RewriteRule ^(.*)$ index.php?/$1 [L]

RewriteCond %{REQUEST_FILENAME} !-f

RewriteCond %{REQUEST_FILENAME} !-d

RewriteRule ^(.+)$ index.php?/$1 [L]



I am wondering if Wordfence is my problem, as there is this in the PHP configuration:

auto_prepend_file  /home/content/50/8634350/html/wordfence-waf.php



And this in /user.ini

; Wordfence WAF

auto_prepend_file = '/home/content/50/8634350/html/wordfence-waf.php'

; END Wordfence WAF



The root also has an .htaccess with the following, which is the way I inherited this can of worms;

RewriteEngine on

RewriteRule ^6052317648/(.*)$ inconvertible-exclaiming.php [QSA,L]



RewriteEngine On



RewriteCond %{ENV:REDIRECT_STATUS} 200

RewriteRule ^ - [L]

RewriteCond %{REQUEST_FILENAME} !-f

RewriteCond %{REQUEST_FILENAME} !-d

RewriteCond %{HTTP_USER_AGENT} (google|yahoo|msn|aol|bing) [OR]

RewriteCond %{HTTP_REFERER} (google|yahoo|msn|aol|bing)

RewriteRule ^(.*)$ ironwood-insure.php?$1 [L]



# BEGIN WordPress

<IfModule mod_rewrite.c>

RewriteEngine On

RewriteBase /

RewriteRule ^index\.php$ - [L]

RewriteCond %{REQUEST_FILENAME} !-f

RewriteCond %{REQUEST_FILENAME} !-d

RewriteRule . /index.php [L]

</IfModule>



# END WordPress





# Wordfence WAF

<Files ".user.ini">

<IfModule mod_authz_core.c>

Require all denied

</IfModule>

<IfModule !mod_authz_core.c>

Order deny,allow

Deny from all

</IfModule>

</Files>



# END Wordfence WAF





Also I was testing to see if mod_rewrite was working and found that this doesn't work on the Godaddy site, but does on working site.

RewriteRule ^link([^/]*).html$ rewrite.php?link=$1 [L]

If I explicitly set the base like this it works on Godaddy. 

RewriteBase /test/

RewriteRule ^link([^/]*).html$ rewrite.php?link=$1 [L]



I don't need to get rid of needing index.php, as this is for a backend application, I just need it to work.
Has anyone gotten CodeIgniter to work on a similar configuration?
Reply


Messages In This Thread
No input file specified. Godaddy - by RMaynard - 12-08-2017, 10:46 AM



Theme © iAndrew 2016 - Forum software by © MyBB