Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


How to use session in cakephp?



How to use session in cakephp?..

Answer / Bibhas Kumar

In CakePHP, you can use sessions by calling the `Session` component. First, add Session as a component in your controller:n```phpnpublic $components = array('Session');n``` Then, to set a session variable, use:n```phpn$this->Session->write('key', 'value');n``` To read a session variable, use:n```phpn$value = $this->Session->read('key');n```

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More CakePHP Interview Questions

How to fetch data from database in cakephp?

1 Answers  


How many types of caches does cakephp support?

1 Answers  


What do you mean by component in cakephp?

1 Answers  


List different type of cache cakephp supports?

1 Answers  


How do I set up cakephp?

1 Answers  


How to get current url in cakephp?

1 Answers  


What is name of default function and controller of cakephp which is called automatically?

1 Answers  


What is helper in cakephp?

1 Answers  


What is default function and default controller of cakephp which is called automatically?

1 Answers  


List minimum server requirements to install cakephp?

1 Answers  


What are commonly used helpers of cakephp?

1 Answers  


How cakephp url looks in address bar

1 Answers  


Categories