Ask, is it possible to make a file without a. php suffix in the lamp environment executable script
To give a simple example:
echo ' Hello world! ';
?>
If saved as hw.php, of course everything is OK.
If saved as HW (no suffix), when accessing HTTP://WWW.DOMAIN.COM/HW through a browser,
The source code is directly printed out.
Excuse me, is it possible to let such a file without a suffix be executed like an ordinary. php file.
------Solution--------------------
Can be configured through a column-only directory Access: http://xxxxxxxx/the page is out.
------Solution--------------------
Http://www.domain.com/hw
The HW in is generally the controller name in the MVC structure, or implemented through rewrite.
------Solution--------------------
I don't know what you mean.
If you just want to hide the entry file name, then you just have to.
Rewritecond%{request_filename}!-d
Rewritecond%{request_filename}!-f
Rewriterule ^ (. *) $ index.php/$1 [qsa,pt,l]
So all the schedules are index.php by analyzing $_server[' path_info ')
Which means a set of programs can manage all user directories.
If a separate site system is required for each user directory or for a few user directories. Then copy this. htaccess to the corresponding directory.