Caution: This documentation is for eZ Publish legacy, from version 3.x to 5.x.
For 5.x documentation covering Platform see eZ Documentation Center, for difference between legacy and Platform see 5.x Architecture overview.



Fetches the number of anonymous users.


fetch( 'user', 'anonymous_count' )


The number of anonymous users as an integer.


This function counts the number of anonymous users currently accessing the site and returns that count (as an integer). An anonymous user is considered to be active if the last access time within the range of the activity timeout. The timeout can be set using the "ActivityTimeout" directive in a configuration override for "site.ini". The default timeout is one hour.


Example 1

{def $visitors=fetch( 'user', 'anonymous_count' )}
There are {$visitors} anonymous users accessing the site.

Outputs the number of anonymous users that are currently accessing the site.

Balazs Halasy (01/06/2004 3:45 pm)

Svitlana Shatokhina (30/03/2006 10:07 am)


There are no comments.