Session info taglib ver. 1.2


    Custom JSP tags library lets you calculate information attributes for the current session. For example:
 


<%@ taglib uri="taglib.tld" prefix="s" %>
<html>
<p><i> Session used time is:</i> <s:sessionUsedTime formatted="true"/>
</html>

Tags are:

sessionUsedTime

Calculates the usage time for your session (in milliseconds). Attributes are:

1) id Optional attribute describes a page scope variable for data (type is java.lang.Long or java.lang.String depends on attribute formatted). Without this attribute tag just prints data.
2) formatted Optional attribute. Possible values are true or false. If this value is true than tag will print a formatted value (hous:minutes:seconds). Default value is false.

sessionInactiveTime

Calculates the inactivity time (time since last call of this tag) for your session (in milliseconds). Attributes are:

1) id Optional attribute describes a page scope variable for data (type is java.lang.Long or java.lang.String depends on attribute formatted). Without this attribute tag just prints data.
2) formatted Optional attribute. Possible values are true or false. If this value is true than tag will print a formatted value (hous:minutes:seconds). Default value is false.

isNewSession

Body tag executes own body if session is new. Attributes are: none

isNotNewSession

Body tag executes own body if session is not new. Attributes are: none

validSession

Body tag executes own body if session is valid. Attributes are: none

for downloading:

 Library: sessinfotag.jar     Description: taglib.tld

 © Coldbeans      Comments?

See also Coldtags suite - the largest collection of custom JSP tags.

     

Also in JSOS: