Ask thinkphp to write the code session. the code is like this & nbsp; public & nbsp; function & nbsp; index () {$ namecookie (name ); $ messgetuserlink (); $ id]; session (addressid, $ id); coo asks questions about the session code written in thinkphp
The code is like this
Public function index (){
$ Name = cookie ('name ');
$ Mess = getuserlink ();
$ Id = $ _ GET ['id'];
Session ('ssid SSID ', $ id );
Cookies ("goodsid", $ id, 3600000 );
Dump (session ('address '));
Dump (cookie ('goodsid '));
In fact, it is to save the id parameter to the session for use on other pages, and it has been confirmed correct by using dump.
The result is as follows:
String (32) "88d2a7d29f90075584073212a2883ab8"
String (32) "88d2a7d29f90075584073212a2883ab8"
But after a page is changed
Public function index (){
$ Name = cookie ('name ');
$ Mess = getuserlink ();
If (is_null ($ name )){
$ Name = fy ('tourists ');
}
Dump (session ("addressid "));
Echo ("======= cookie
");
Echo (cookie ("goodsid "));
Echo ("======= cookie ");
The displayed result is
String (71) "templatesquare & count = 1 & callback = jquery16409371740901_102_14208544222"
======= Cookie
Templatesquare & count = 1 & callback = jquery16409371740901_102_1420208544222 ====== cookie
Does anyone know what is going on?
------ Solution ----------------------
String (71) "templatesquare & count = 1 & callback = jquery16409371740901_102_14208544222"
======= Cookie
Templatesquare & count = 1 & callback = jquery16409371740901_102_1420208544222 ====== cookie
Excuse me, are you two different?
------ Solution ----------------------
String (71) "templatesquare & count = 1 & callback = jquery16409371740901_102_14208544222"
======= Cookie
Templatesquare & count = 1 & callback = jquery16409371740901_102_1420208544222 ====== cookie
Same.
------ Solution ----------------------
You didn't get it. how can you see it?
That is the url parameter of the jquery jsonp request.