When writing the
php验证码
page, the php file is stored on the Sina cloud server, want to use the
javascript
Ajax request in the page
session
to verify the verification code, feel that this method should be feasible, but the actual operation, but found that
ajax
the use of the
session
always empty , and did not request to, one is the code is wrong, think, all kinds of consulting, finally found that the Netizen said that Sina Cloud can not save
session
, but I use to
form
do the request, but it is possible to get the
session
value, this for what, solve ...
Reply content:
When writing the php验证码
page, the php file is stored on the Sina cloud server, want to use the javascript
Ajax request in the page session
to verify the verification code, feel this method should be feasible, but the actual operation, but found that ajax
the use of the session
always empty, And did not request to, one is the code is wrong, think, all kinds of consulting, finally found that the Netizen said that Sina Cloud can not save session
, but I use to form
do the request, but to get the session
value, this for what, solve ...
Without the framework, the PHP file must be preceded by session_start (), and then the file will be $_session.