With the thinkphp frame.
Input in Browser
http://127.0.0.1/NovoMagic/index.php/Dac/Test/d
Automatically jump to the login page
Http://127.0.0.1/NovoMagic/index.php/Home/Login/index.html
I didn't write anything in the/dac/test/d. Why would you jump to the login page?
Using Firebug to view the network situation is as follows:
Why it automatically jumps to the login page.
PS: If I log in, then access to http://127.0.0.1/NovoMagic/index.php/Dac/Test/d is no problem.
So it seems like I realized the function of the interceptor, all the URLs automatically intercept ah .... But I don't have anything to configure.
Reply to discussion (solution)
TP is unfamiliar. Guess is that you inherited the controller or a call to the file has a login detection.
specifically to read the code before you know.
Your introduction of the file common.php, is not written in what Dongdong, such as init initialization function.
Magic question, do you see the controller inside and you introduced the common.php inside is there is a judge whether the login code?
Thinkphp has a _initialize () method that runs this method automatically when any function of this module is run
Do you want to see if the file has this method?
Initialization method has to determine whether the login code, landlord check.
You should route the problem, see if you use Nginx? Your nginx uses TP need to configure routing, and use the routing mode to change to
' Url_model ' + 0,//URL access mode, optional parameters 0, 1, 2, 3, representing the following four modes
Give it a try
Look at the log log in runtime at a glance.
Thank you for your attention. Finally found that he used the TP similar to the filter of the object Control permission.
Alas, rewriting someone else's code is really hard.