Private vairable not working |
On the top above my __construct() area in my library I have a variable called $set_the_time_for_cookie_to_expire because the time() has brackets it is throwing error
Code: A PHP Error was encountered Is there any way to be able to use php time() like what I am after? PHP Code: private $customer_id;
There's only one rule - please don't tell anyone to go and read the manual. Sometimes the manual just SUCKS!
Create a set and get method to set and get the cookie expire time.
What did you Try? What did you Get? What did you Expect?
Joined CodeIgniter Community 2009. ( Skype: insitfx )
Assign the value in the __construct method.
PHP Code: private $set_the_time_for_cookie_to_expire;
Yep that will work also but I would still create the set and get methods so that if you ever want to change the expiration time you can.
What did you Try? What did you Get? What did you Expect?
Joined CodeIgniter Community 2009. ( Skype: insitfx )
|
Welcome Guest, Not a member yet? Register Sign In |