php (as the current mainstream development language) The session function in 4 can be said to be quite perfect. It has corrected many bugs in previous versions and is very convenient to use. The difference from the session in asp is that php (as the current mainstream development language)4 stores the session value in the web server, not the client. Generally speaking, it is in the mp directory. If this directory does not exist, the following error will occur:
Warning: open( mpsess_3a1118cbf345a4950254946fc8e5935e, O_RDWR) failed: m (2)
Can be found in php( As the current mainstream development language) add this directory to the running directory.
You can also modify php(as the current mainstream development language).ini file under [session]: session.save_path =
By adding session_save_path( "");You can also specify a path.
Then you can perform session operations such as:
(as the current mainstream development language)
session_save_path("temp");
session_start(); asd!=""){
session_register("asd");}
if(($pwd!=$asd)&&($pwd!="")){$asd=$ pwd;}
?>
The above saves $asd in the directory temp specified in the session and uses $asd=$pwd to change the value of $asd in the session. The definition of session can only be done before. The use of session variables is not subject to this restriction, but it must be defined first and then used.