Forums / Setup & design / desperate: session id or other unique key required

desperate: session id or other unique key required

Author Message

Alessandro Cipriani

Tuesday 02 March 2004 7:54:38 am

hi all

i need something unique to identificate the current browser session... how can i do it?

http://ez.no/community/forum/setup_design/how_to_retrieve_session_id

i've seen operators, but nothing that can fit to my need!!!
i've got to call an external site with an unique param and i thought that session id will be the goal... but how to retrieve it????

best regards

alessandro

James Packham

Wednesday 03 March 2004 2:53:03 am

I'm not sure if this helps, as I don't really understand what it is you're trying to do. I just stumbled accross this variable and remembered your post.

$http.session

do an attribute(show) on it, this is what I get:

Attribute Type Value
eZUserLoggedInID NULL
eZUserInfoCache_Timestamp integer 1078310917
eZUserInfoCache array Array(1)
>10 array Array(5)
eZUserGroupsCache_Timestamp integer 1078310917
eZUserGroupsCache array Array(1)
>10 array Array(1)
PermissionCachedForUserID string 10
PermissionCachedForUserIDTimestamp integer 1078310915
UserRoles array Array(1)
>0 array Array(2)
eZGlobalSection array Array(1)
>id string 1
RegisterUserID integer 793
UserPolicies array Array(1)
>1 array Array(9)
UserLimitations array Array(6)
>702 array Array(1)
>703 array Array(1)
>704 array Array(2)
>708 array Array(3)
>705 array Array(3)
>709 array Array(3)
UserLimitationValues array Array(8)
>899 array Array(13)
>912 array Array(13)
>902 array Array(1)
>907 array Array(1)
>901 array Array(1)
>906 array Array(1)
>903 array Array(1)
>909 array Array(1)

Hope that helped!

Regards,

James

Alessandro Cipriani

Wednesday 03 March 2004 3:13:56 am

hi james
great! i feel we are getting the solution now!

please, can you be more clear? when you write
"$http.session

do an attribute(show) on it, this is what I get:

"

what do you mean?
i wrote
"{$http.session.show()}" but i got no output...

i'm trying to get the session id because i need something unique for each session, because then i'll got to call another site with this parameter ("session=9813494189" ecc...)

so i think that the session id will fit my need (because i don't need to generate it, but it's already existant.)

hope i've been more clear

best regards
alessandro

James Packham

Wednesday 03 March 2004 4:05:31 am

Sorry, what I mean is:

{$http.session|attribute(show)}

:)

~James~

Alessandro Cipriani

Wednesday 03 March 2004 5:27:47 am

ok james,
i wrote exactly "{$http.session|attribute(show)}"
but i get only 'Attribute Type Value', without the other values as you wrote...

James Packham

Wednesday 03 March 2004 6:45:23 am

Try {$http|attribute(show)}, if still nothing then there aren't any http variables available. I used this on the registration template, so all mine refer to those available during registration. However, I would have thought that session would be fairly generic.

Regards,

James