No input file specified Codeigniter

No input file specified error is related to .htaccess in Codeigniter. We just have to change the rewrite engine rules in .htaccess to avoid this error.

Answers 1
  • No input file specified error solving using htaccess in Codeigniter 4

    --PATH public\.htaccess
    RewriteRule ^([\s\S]*)$ index.php/$1 [L,NC,QSA]
    #Replace with below code 
    RewriteRule ^([\s\S]*)$ index.php?/$1 [L,NC,QSA]

    Find RewriteRule ^([\s\S]*)$ index.php/$1 [L,NC,QSA]  using ctrl + f after that replace code with RewriteRule ^([\s\S]*)$ index.php?/$1 [L,NC,QSA]. The changes between these codes is only a ? which have to add after RewriteRule ^([\s\S]*)$ index.php in .htaccess file under public directory.

    Or you can simply add ? mark after index.php in that particular line of .htaccess code.

  • Back to code snippet queries related codeIgniter