Home  >  Q&A  >  body text

No input file specified. How to solve this?

No input file specified.How to solve this

................2101 days ago3071

reply all(8)I'll reply

  • 王先生

    王先生2019-10-28 11:04:09

    Done, it is indeed a problem configured in the .htaccess file. At first I couldn't find where this file was placed. There was a lot of nonsense on the Internet. Some information said that this file should be modified, but there was no explanation of where this file was placed (the file could not be found. Then I need to modify the thread).

    .htaccess This file is under the \tp5\public directory. Open this file and put RewriteRule ^(.*)$ index.php/$1 [QSA,PT,L] in the line after index.php Add a question mark "?" (question mark in English):

    Before modification:

    <IfModule mod_rewrite.c>

    Options FollowSymlinks -Multiviews

    RewriteEngine On

    RewriteCond %{REQUEST_FILENAME} !-d

    RewriteCond %{REQUEST_FILENAME} !-f

    RewriteRule ^(.*)$ index.php/$1 [QSA,PT,L]

    </IfModule>

    Modify After

    <IfModule mod_rewrite.c>

    Options FollowSymlinks -Multiviews

    RewriteEngine On


    ## RewriteCond %{REQUEST_FILENAME} !-d

    RewriteCond %{REQUEST_FILENAME} !-f

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

    </IfModule>


    ##Remember to restart the Apache server after modification.

    Later I looked for a lot of information and found that https://blog.csdn.net/marswill/article/details/88574607 this person wrote the same thing as I realized it myself

    If this file is not found, you may need to enable .htaccess first. The enabling method is as follows:

    Open httpd.conf (where? In the CONF directory of the APACHE directory), open it with a text editor, and search for

    AllowOverride None

    Modify it to

    AllowOverride All


    Remove the comment in front of mod_rewrite.so (just delete the # (pound sign) or; (semicolon) in front of it)

    LoadModule rewrite_module modules/mod_rewrite.so


    ##Hope it helps, brother. This is how I solved my problem

    reply
    0
  • 王先生

    王先生2019-10-28 10:15:56

    Same problem, tried many methods but nothing worked. It says that I need to modify a .htaccess file, but I can’t find the file

    reply
    0
  • 晨风不可依米

    晨风不可依米2019-03-16 00:06:18

    I also have this problem, how did you solve it before? please inform!

    reply
    0
  • 天蓬老师

    天蓬老师2018-12-21 23:43:23

    This prompt will also appear if the PHP version is too low, try switching to 7.0+

    reply
    0
  • ........

    Thank you, but it still doesn't work. The error always appears. Is there any other way?

    ........ · 2018-12-21 23:47:33
  • ........

    ........2018-12-21 23:38:31

    <?php
    /**
     * Created by PhpStorm.
     * User: Administrator
     * Date: 2018/12/21 0021
     * Time: 下午 15:02
     */
    
    namespace app\admin\controller;   
    use think\facade\config;    
    class user
    {
          public function get()    
          {
             dump(config::get());    
           }
    }

    无标题.png still displays No input file specified

    reply
    0
  • 我★独依→亻

    我★独依→亻2018-12-21 17:43:20

    The path is wrong. . .

    reply
    0
  • 晨风不可依米

    Where is the path wrong?

    晨风不可依米 · 2019-03-16 00:05:22
  • Cancelreply