Home > Contents > Index >
RENDER.SATELLITEBLOB
Creates a URL in a complete HTML tag that retrieves a blob from a table or from the CS-Satellite cache.
Syntax
<RENDER.SATELLITEBLOB SERVICE="HTMLtagName
" [BLOBTABLE="blobTable
"] [BLOBKEY="primaryKeyName
"] [BLOBWHERE="primaryKeyValue
"] [BLOBCOL="column name
"] [C="asset type
"] [CID="asset id
"] [ASSET="asset instance name
"] [FIELD="asset field name
"] [BLOBHEADER="MIMEtype
"] [ARGS_format1="5
"] [CACHECONTROL="expirationDateAndTime
" [BLOBLHEADERNAMEN="blob header name"] [BLOBHEADERVALUEN="blob header value"] [CSBLOBID="session variable value" />Parameters
SERVICE (required)
- Input. The start of the HTML tag to hold the reference to the blob. For example, if the blob is an image, use
SERVICE="IMG SRC"
.
BLOBTABLE (optional)
- Input. Name of a ContentServer database table that stores binary data. For example,
BLOBTABLE="ImageFile"
.
BLOBKEY (required, if BLOBTABLE set)
- Input. Name of the database column used as the primary key. Typically, this is
id
.
BLOBWHERE (required, if BLOBTABLE set)
- Input. Primary key value describing the row containing the binary data to be served.
BLOBCOL (required, if BLOBTABLE set)
- Input. Name of the database table column that contains the binary data. For example, for the Imagefile database table,
BLOBCOL="urlpicture"
.
FIELD (required, if BLOBTABLE not set)
- Input. The name of an asset field containing binary data to be served.
ASSET (optional)
- Input. Name of an asset instance.
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.
BLOBHEADER (required)
- The mimetype for returned data, in the form
description/extension
. For example, the mimetype for a GIF image isimage/gif
.
ARGS_ (optional)
- Input. Name/value modifiers for the HTML tag, with the string
ARGS
_as the prefix. For example,ARGS_vspace="5"
,ARGS_hspace="5"
, and so on.
CACHECONTROL (optional)
- Input. Determines for how long to cache the blob. See satellite.blob for details about this parameter.
BLOBHEADERNAMEN (optional)
- This parameter set specific HTTP header variables to suit your needs, The
BLOBHEADERNAME
parameter is used in conjunction with theBLOBHEADERVALUE
parameter to produce name/value pairs. This parameter represents the variable name.
BLOHEADERVALUEN (optional)
- This parameter is used in conjunction with
BLOBHEADERNAME
to specify and represent HTTP header variable values.
CSBLOBID (optional)
- The 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 thecsblobid
parameter was set. When BlobServer security is set to true and thecsblobid
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.
Description
This tag is the CS-Direct equivalent of the CS-Satellite
SATELLITE.BLOB
tag, with the following exception:
rendermode
is passed in automatically.You can use
BLOBHEADERNAME
andBLOBHEADERVALUE
to specify http headers in the BlobServer response. For example, you can specify the content-type as follows:BLOBHEADERNAME1="Content-Type" BLOBHEADERVALUE1="image/gif"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.
BLOBHEADERNAME1="Cache-Control" BLOBHEADERVALUE1="no-cache" BLOBHEADERNAME2="Pragma" BLOBHEADERVALUE2="no-cache"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 thesatellite.page.cachecontrol.default
property, found in thefuturetense.ini
property file, is used.
3. If there is no value in
satellite.page.cachecontrol.default
, the value of theexpiration
property, located in thesatellite.ini
property file, is used.We recommend that you set values for theNOTE: The table name containing the blob, the primary key of the table, the id of the table row, and the column name that contains the binary data are all optional parameters. The same information can be provided to this tag by specifying an asset type, id and field name, or an asset instance object name and field name. However, there is an advantage to using the latter forms. If the owning asset is changed, Blob Server will invalidate the cached blob, but only if it was served via one of the asset forms of the RENDER.SATELLITEBLOB tag.satellite.page.cachecontrol.default
properties that make sense for the majority of your pages and pagelets. If you want to override the default expiration time, use theCACHECONTROL
parameter. Use the expiration property to determine the timeout for pages that are not generated from this tag; for example, pages that are generated directly from a URL.errno
None.
Examples
This code creates an HTML <
IMG SRC>
tag. TheSRC
is the blob in the ImageFile table identified through the ID passed in withBLOBWHERE="Variables.asset:id"
and both its horizontal and vertical spacing are at five pixels:<RENDER.SATELLITEBLOB BLOBTABLE="ImageFile" BLOBKEY="id" BLOBCOL="urlpicture" BLOBWHERE="Variables.asset:id" BLOBHEADER= "Variables.asset:mimetype" SERVICE="IMG SRC" ARGS_alt= "Variables.asset:alttext" ARGS_hspace="5" ARGS_vspace="5" />This code does the same thing, but the cached blob will be invalidated when the ImageFile asset is modified:
<RENDER.SATELLITEBLOB C="ImageFile" FIELD="urlpicture" CID="Variables.asset:id" BLOBHEADER= "Variables.asset:mimetype" SERVICE="IMG SRC" ARGS_alt= "Variables.asset:alttext" ARGS_hspace="5" ARGS_vspace="5" />This code does the same thing, but uses an already-loaded asset instance:
<ASSET.LOAD TYPE="ImageFile" OBJECTID="Variables.asset:id" NAME="myasset"/> <RENDER.SATELLITEBLOB ASSET="myasset" FIELD="urlpicture" BLOBHEADER= "Variables.asset:mimetype" SERVICE="IMG SRC" ARGS_alt= "Variables.asset:alttext" ARGS_hspace="5" ARGS_vspace="5" />See Also
RENDER.SATELLITEPAGE
satellite.blob
Home > Contents > Index > ![]()
FatWire XML Tag Reference
Copyright 2005 by FatWire Software
All rights reserved.