Welcome Guest, Not a member yet? Register   Sign In
How to get userdata from encrypted sessions database according to session id?
#15

[eluser]pickupman[/eluser]
Quote:But how can you pass this to the JavaScript file? You can’t just put <?php echo $session_id; ?> in a .js file. How is this commonly done?

Sometimes you need to use a php file extension. As long as it falls in a script tag to include the source. It will get parsed as php by the server, and interpreted by the browser as javascript. With CI, other than including jQuery source or plugins, all of my js scripting is done in php files.


Messages In This Thread
How to get userdata from encrypted sessions database according to session id? - by El Forum - 07-17-2010, 03:35 PM



Theme © iAndrew 2016 - Forum software by © MyBB