Session are not accessible in site.php (config file)
When i try to access session from site.php of config the session are not available over there, So i tried to do session_start() from site.php but that is giving me error as below :
Fatal error: Concrete5_Model_PermissionAccess::validateAndFilterAccessEntities(): The script tried to execute a method or access a property of an incomplete object. Please ensure that the class definition "GroupPermissionAccessEntity" of the object you are trying to operate on was loaded _before_ unserialize() gets called or provide a __autoload() function to load the class definition in /home/c2085051/public_html/updates/concrete18.104.22.168/concrete/core/models/permission/access/model.php on line 51
So what wrong i am doing here ? And what is the way with which i can access the session from site.php, please help to get me solution of it
Thanks for your reply.
I am trying for language change on the ecommerce checkout page , as my site is in multi language, so if user have danish selected then i want to keep danish on checkout pages but it dont works there. So i am trying that with session in site.php where i can set the language parameters but session are not accessible over there, So not sure how i will be able to do so. Please help to get me out of this.
But nonetheless, the reason why you can't access the session is because the session in concrete5 has a name "CONCRETE5", you'd have to set that name first..
Thanks for your guide.
We the multilanguge package but that is not working for the pages that don't have language parameter in url. So it is not helping us on checkout pages, so i need to do with session. Is there any other way i can go with ?
I currently can't find the discussion but I'll have another look later
I tried to set session name in config file still when i do session_start under it , it gives me error
Fatal error: Concrete5_Model_PermissionAccess::validateAndFilterAccessEntities(): The script tried to execute a method or access a property of an incomplete object. Please ensure that the class definition "GroupPermissionAccessEntity" of the object you are trying to operate on was loaded _before_ unserialize() gets called or provide a __autoload() function to load the class definition in /home/c2085051/public_html/updates/concrete22.214.171.124/concrete/core/models/permission/access/model.php on line 101
is there any way i can solve it?
I'd focus on the internationalization add-on
I tried to find in forum i found below discussion :
In here also at lastly they have mentioned to use session and no final solution is there. So let me know if anything help me on it, as i am stuck here. Thanks for your all help.
The method shown here might work in the controller of the internationlization add-on:
But as I said, it's possible that there's a dependency which the official core doesn't meet. But you should still be able to get the session part out of it..
The link you gave from there i have placed the function in my package but that is not helping, tried to find other thing in that post but not sure if anything else i need to further to make it working.
John not sure for your reply i am not able to get it.
I have tried with many thing , you are right we can ignore the coding from site.php , but still i need to change in core files that is either config file localization.php or dispatcher.php ( which cant not be over ride outsite). In that when the c5 updated the changes are gone.
For now i do changes are in
(config/)localization.php(by commeting active_locale from here) / dispatcher.php (Or by moving localization line after package)(any of one)
library/localization.php => access session from here.
config/site_theme_paths.php => making session here.
So can you help me find the prominant solution for it.