Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 0.5.6

Request #9607 get() / set() by reference
Submitted: 2006-12-13 20:56 UTC
From: wiesemann Assigned: troehr
Status: Closed Package: HTTP_Session (version 0.5.4)
PHP Version: Irrelevant OS: Irrelevant
Roadmaps: (Not assigned)    
Subscription  


 [2006-12-13 20:56 UTC] wiesemann (Mark Wiesemann)
Description: ------------ Today I have tried to make a big application "register_globals = off" compatible. So far, the application used global variables and called then session_register("var_name");. Obviously something that won't work with r_g = off. The current get() and set() methods are nice, but not enough IMHO. It would be nice to have new getRef() and setRef() methods that return / get the value by reference. The $default possibility in get() and the unset() possibility in set() wouldn't be needed in these new methods and they could be rather short. This would be a great addition because it makes the transition from old session usage to a safe session usage (with rg=off) very easy. If you need more details or want me to make a patch, please tell me. Thanks.

Comments

 [2006-12-16 13:40 UTC] troehr (Torsten Roehr)
Thank you for your bug report. This issue has been fixed in the latest released version of the package, which you can download at http://pear.php.net/get/HTTP_Session