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

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 19 2025 04:23:45
Script start
Timing: Jan 19 2025 04:23:45
Module start 'layout'
Timing: Jan 19 2025 04:23:45
Module start 'content'
Timing: Jan 19 2025 04:23:46
Module end 'content'
Timing: Jan 19 2025 04:23:46
Script end

Main resources:

Total runtime0.8700 sec
Peak memory usage4,096.0000 KB
Database Queries66

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0054 589.3047152.6406
Module start 'layout' 0.00540.0029 741.945339.4766
Module start 'content' 0.00830.8601 781.4219557.8281
Module end 'content' 0.86840.0015 1,339.250016.1250
Script end 0.8699  1,355.3750 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.01091.2498160.0007
Check MTime0.00911.0437160.0006
Mysql Total
Database connection0.00060.074310.0006
Mysqli_queries0.784890.2074660.0119
Looping result0.00060.0694640.0000
Template Total0.838796.420.4193
Template load0.01021.172720.0051
Template processing0.828595.229720.4142
Template load and register function0.00010.011810.0001
states
state_id_array0.00090.101710.0009
state_identifier_array0.00310.354920.0015
Override
Cache load0.01001.1504850.0001
Sytem overhead
Fetch class attribute can translate value0.00050.063120.0003
Fetch class attribute name0.00130.146380.0002
XML
Image XML parsing0.00110.131320.0006
class_abstraction
Instantiating content class attribute0.00000.0036120.0000
General
dbfile0.00220.2562220.0001
String conversion0.00000.000940.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
6content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
6content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
11content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
7content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 32
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs