Home > Contents > Index >
Template Tag TOC  |   Alpha TOC  |   Tag Family TOC  |   Purpose TOC  |   Annotated TOC  |   Index 



Retrieves a blob from a table or from the Sites-Satellite cache.


       [ASSEMBLER="uri assembler shortform"]
       [ASSET="asset instance name"]
       [AUTHORITY="authority value"]
       [BLOBCOL="column name"]
       [C="asset type"]
       [CID="asset id"]
       [CSBLOBID="session variable value"]
       [FIELD="asset field name"]
       [FRAGMENT="fragment value"]
       [PARENTID="parent to log this blob as a dependency"]
       [SCHEME="scheme value"]

      [<RENDER.ARGUMENT NAME="argname" VALUE="argvalue"/>]



assembler (optional)
Short form name for uri assembler class. Specifying an assembler overrides the default assembler used by Sites to construct URLs. Omitting this value will cause URLs generated by this tag to use the assembler registered with the highest priority in the request property file.
authority (optional, required if scheme is set)
Attribute that allows the user to specify a fully-qualified URL, when used in conjunction with scheme. URLs are of the form scheme://authority/path?query#fragment. For most purposes, authority corresponds to host:port for the given application. Specifying scheme and authority allows for fully-qualified URLs to be created, which is useful for sites with multiple domains and in other cases.
service (optional)
Input. Start of the HTML tag to hold the reference to the blob. For example, if the blob is an image, use service="img src". The default value is img src.
blobtable (optional)
Input. Name of the Sites table that stores assets of this type. For example, blobtable="ImageFile".
blobkey (required, if blobtable set)
Input. Name of the column used as the primary key. Typically this is id.
blobwhere (required, if blobtable set)
Input. Object ID of the asset.
blobcol (required, if blobtable set)
Input. Name of the column that contains the binary data. For example, for the imagefile asset type, blobcol="urlpicture".
blobnocache (optional)
True or false. If set to true, the blob and the header will not be cached on either Sites or Satellite Server. The default value is false.
c (required, if asset and blobtable not set)
Input. An asset type name.
cid (required, if asset and blobtable not set)
Input. An asset identifier.
asset (optional)
Input. Name of an asset instance.
field (required, if blobtable not set)
Input. The name of an asset field containing binary data to be served.
fragment (optional)
Optional attribute to specify a fragment on the URL. Fragments, sometimes known as anchors, allow browsers to advance to a specific location in a single web page. ex. http://www.myhost.com/foo.html#thirdParagraph.
container (optional)
Override attribute that specifies whether the URL will be generated for a servlet container or a portlet container. By default, the current container will be used. For practical purposes, leaving this blank or setting it to servlet should be sufficient. Legal values are servlet and portlet.
blobheader (required)
Mimetype for returned data, in the form description/extension. For example, the mimetype for a GIF image is image/gif.
cachecontrol (optional)
Input. Determines for how long to cache the blob. See satellite.blob for details about this parameter.
csblobid (optional)
Value of this parameter must correspond to a session variable of the same name when BlobServer security is on. When a request is made to the BlobServer, the img src service parameter sends a new request to the application server after the browser reads the containing page. BlobServer then verifies if the csblobid parameter was set. When BlobServer security is set to true and the csblobid value matches the session variable value, the blob is served. If the values do not match, a security violation is reported and no blob is served.
satellite (optional)
Override attribute that forces the URL generated to be a URL for either Satellite Server or Sites. By default, the URL will automatically be set to whatever the containing page is set to. Legal values are true (Satellite Server URL) and false (Sites URL).
parentid (optional)
The id against which this blob should be logged as a dependency. When a blob is cached, an item dependency can be recorded against the cache key to provide a content-based identifier for accessing the cached blob, rather than requiring the cache key to do so. This is useful in cache management. When coupled with an asset identifier, this can allow blobs to be flushed when an asset is updated.
scheme (optional, required if authority is set)
Attribute that allows the scheme to be set in the URL. The scheme in the case of most URLs refers to the protocol and is usually set to either http or https. If this is left blank (and authority is left blank) then the URL will be relative to the current scheme and authority.
preferredfile (optional)
Attribute to specify a preferred filename. Only used for static publishing.


Input. Name/value modifiers for the HTML tag.


This tag is equivalent of Sites-Satellite satellite.blob tag, with the following exception:

You can use the blobheadername and blobheadervalue parameters to specify http headers in the BlobServer response. For example, you can specify the content-type as follows:


If you want to use http headers to prevent browser caching of BlobServer requests for all browsers, use both HTTP 1.0 and HTTP 1.0 cache control directives. In the following example, the first header (Cache-Control:no-cache) is the HTTP 1.1 directive and the second header (Pragma:no-cache) is the HTTP 1.0 directive.



To determine how long to cache a page or pagelet, these criteria are evaluated in this order:

  1. A value passed in using the cachecontrol parameter.
  2. If there is no value in cachecontrol, the value in the satellite.blob.cachecontrol.default property, found in the futuretense.ini property file, is used.
  3. If there is no value in satellite.page.cachecontrol.default, the value of the expiration property, located in the satellite.properties property file, is used.

We recommend that the cachecontrol attribute be set for all blobs. If all blobs will have the same expiry, then consider setting the satellite.blob.cachecontrol.default property instead. Because the cache is actively managed when compositional dependencies are properly recorded, blobs can be set to never expire. This ensures that they always remain in cache, and the cache manager will ensure that they remain up-to-date..

Error Numbers

There are no possible errno for this tag.


The example below is in JSP. The XML syntax is analogous. This code creates an HTML <img> tag. The src attribute is the blob in the ImageFile table identified through the ID passed in with blobwhere='<%=ics.GetVar("asset:id")%>' and both its horizontal and vertical spacing are at five pixels:

        service="img src">
    <render:argument name="alt" value='<%=ics.GetVar("asset:alttext")%>'/>
    <render:argument name="hspace" value="5"/>
    <render:argument name="vspace" value="5"/>

This code does the same, but the cached blob will be invalidated when the corresponding ImageFile asset is changed:

        service="img src">
    <render:argument name="alt" value='<%=ics.GetVar("asset:alttext")%>'/>
    <render:argument name="hspace" value="5"/>
    <render:argument name="vspace" value="5"/>

This code does the same, but uses an already-loaded ImageFile asset instead:

        service="img src">
    <render:argument name="alt" value='<%=ics.GetVar("asset:alttext")%>'/>
    <render:argument name="hspace" value="5"/>
    <render:argument name="vspace" value="5"/>

This example shows how to render a blob for a flex asset using the c and cid parameter. render:satelliteblob logs the dependency for the blob against the asset so that whenever asset is modified the blob is also flushed.

<assetset:setasset name="as" type="Media_C" id="<%=ics.GetVar("asset:id")%>"/>
<!-- Get a set of all values for the given attribute. -->
<assetset:getattributevalues ordering="descending" name="as"
typename="Media_A" attribute="FSII_NameAttr" immediateonly="true" listvarname="results"/>
<ics:listloop listname="results">
<ics:listget listname="results" fieldname="value"/><br/>
        service="img src">
    <render:argument name="alt" value="Image file"/>

It is recommended to use parameters blobtable, blobkey, blobcol, and blobwhere when rendering the blob instead of c and cid. Also log the blob dependency using parentid attribute.

See Also


  Home > Contents > Index >

Oracle XML Tag Reference
Copyright (c) 2013, 2019, Oracle and/or its affiliates. All rights reserved.