thinkPHPd routing settings
风起时丶丶想你
风起时丶丶想你 2018-10-15 11:57:05
0
2
1087

http://localhost:90/ThinkPHP2/index.php/Admin/Login/login

If accessed in the above form, the css or other paths introduced in PHP No longer exists.

http://localhost:90/ThinkPHP2/index.php?s=/Admin/Login/login

If this is the case, the style path will be displayed correctly , how to solve it (the first method is also guaranteed to be correct)


风起时丶丶想你
风起时丶丶想你

reply all(1)
风起时丶丶想你

It has been solved. When introducing files into a page, (./) is generally used to represent the root directory and (../) to represent the upper level. However, this does not work here. It will be considered http://localhost:90/ThinkPHP2/index.php?s=/ Admin/Login/login is the project path, causing an error in the current project path on the page. There is no problem if you use __ROOT_ as the absolute path

  • reply Correction: (./) is the current directory; (/) is the root directory;
    Summer author 2018-10-16 09:38:24
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template