Gets the site associated with a site ID.

Class Name




Input Parameters


The ID of the site to get.

Output Parameters


Rendered if the site is found.


Rendered if the site is not found or siteId is null.


Rendered if an error occurs.


If an error occurs, set with the error message, if any.


Set to the site object of the returned site.

Usage Notes

Given a valid site ID, GetSiteDroplet returns a site object—an implementation of interface atg.multisite.Site—which encapsulates a site configuration. The output parameter enables access to that site’s properties.

You can obtain the current site and its configuration through the Nucleus component /atg/multisite/Site. For example, you can obtain the current site’s ID as follows:

<dsp:tomap bean="/atg/multisite/" var="siteID"/>


The following JSP code obtains the configuration of the site mySite. The output parameter site provides access to all site configuration properties. In this example, the code obtains the site’s closingDate property and compares it to the current date to determine whether the site is active:

<%-- Get the current site configuration and look at its closingDate property --%>
<%@ taglib uri="" prefix="dsp" %>
<%@ page import="java.util.Date;"%>

<dsp:droplet name="/atg/dynamo/droplet/multisite/GetSiteDroplet">
  <dsp:param name="siteId" value="mySite"/>
  <dsp:oparam name="output">
    <dsp:getvalueof var="closeDate" param="site.closingDate"
      <c:when test="${System.currentTimeMillis() < closeDate.getTimeInMillis()}">
        Site is still active
      <c:otherwise> Site is no longer active </c:otherwise>

Copyright © 1997, 2014 Oracle and/or its affiliates. All rights reserved. Legal Notices