Tags
- Octavian
- Derick Ng
- Jorge
- Derick Ng
- Nick
- Derick Ng
- Dav
I'm at Seoul Yummy (United Square 2). http://4sq.com/aKZDsC
I'm at kichn w/ @hanyuan @jeffshi @dfcn84. http://4sq.com/8Lh67j
That is a lot to travel. The holiday starts now! (@@ Sapa Global Hotel w/ @calvinchar @hanyuan @berilyn) http://4sq.com/cZmFwY
Skynet. Yummy. (@@ Tan Son Nhat International Airport (SGN) w/ @hanyuan @berilyn) http://4sq.com/doyPjh
Alright!! (@@ D36 @@ Changi Terminal 1 w/ @calvinchar @berilyn) http://4sq.com/cGukhy
Read: The “Magic” Behind Apple’s New Battery http://bit.ly/diMSou
Read: Changes to Boxes and Application Tabs on Facebook Pages will be implemented starting the week of August 23. ... http://bit.ly/alC6wF
The one good thing about taking the train is the travelling time spent working. Hmm..
Bookmarked 2 links
Lousy day n now I am stuck in the car where I can't reverse and the car in front is freaking near.
CakePHP Losing or Missing Session?
I have my fair share of problems with session in Cake so I thought I can share the two important configurations in
app/config/core.phpwhich affects how Cake handles the session.Session.checkAgentSetting this to
TRUEmeans Cake will store the user agent header of a request when a new session is created. On subsequent request, the user agent header sent is compared with the value stored in the session. If it does not match, the current session will be destroyed and a new session gets created.This rarely causes problem unless you have embedded Flash or Java objects making separate requests to the application. You must take note to send the user agent string of the browser in that case. If you are using something like Aurigma’s Image Uploader where the user agent is not configurable, you have to set this to
FALSEinstead.Security.levelBesides the session timeout, this will affect whether the session ID gets regenerated between requests and whether session.referer_check is set.
With session ID regenerated, there will be problems when your application does any Ajax calls. An Ajax request does not set the cookie as requested by the server which causes the browser to send the session ID of a previous request which will have already been destroyed.
Referrer check is done on the hostname level in Cake and in theory it should not cause any problems. Weirdly, I have a one time login link which redirects user to another location and it works in Firefox but not Internet Explorer. My guess is that Internet Explorer does not set the referrer header properly if it gets redirected. You can log the
HTTP_REFERERheaders to verify that though.Anyways, the valid values:
high” – session ID regenerated and referrer check setmedium” – referrer check setlow” – none