Contents - Index


Docs2Web Interface for Requesting Images or Files

Documents can be accessed either as an image or a PDF document.  This section will explain how to control the size, format, and whether the document is a view or download request.  

Security Control
Any request for an image or PDF will respect the group security.  Any call that either request for an image or PDF from another group the user does not belong to or is not logged into currently shall be treating as if the image does not exists.

Requesting an Image (/dssshowdoc)
Docs2Web has one interface for requesting an image whether you are requesting a full-size document for download, resized to fit a screen, or image thumbnails.  An image is called by sending the path /dssshowdocs.  An example of this call would be:
http://192.168.1.100/d2w-cgi-bin/D2W.dll/dssshowdoc?DOC_ID=30&Page=1&ReqWidth=800&InHTML=True

The section of the link after the "?" are called the parameters, which are all case sensitive.  Some of these parameters are required and some are not.

Required Parameters
DOC_ID-  This commands which document the image will come from.
Page or DOCNUM- This commands which page or DOCNUM the image will come with respect to the DOC_ID passed.  If you are creating thumbnails, use 0 (zero) for this field; this will tell Docs2Web to retrieve the first image page available.

Optional Parameters
ReqWidth (Integer)- This causes Docs2Web to resize the image if it is larger then the requested width.  The resize is always done proportionately.
ToDownload (True or False - Default False)- This parameter when "True" directs the web user's browser to download the file and usually brings up a "Save As" dialog.  When a file is for download, the RequestWidth parameter is ignored.  The file is also downloaded in the format in which it is stored in the database.  When this parameter is "False" or not used, Docs2Web returns the image to the browser for viewing.
InHTML (True or False - Default False)- When this parameter is "True" this directs Docs2Manage to return the image in an HTML page with the image inside the page.  When this parameter is "False" or not used, Docs2Web assumes to return the image as an image content type.  When the InHTML parameter is set to "True", the ToDownload parameter is ignored.

NOTE:  Thumbnails, which are images resized to 300 pixels or less of width, are not consider a page view and are not logged even if Log Page Views is checked.

Requesting an PDF (/dssshowpdf)
Docs2Web has an interface for requesting PDF files (Adobe Acrobat Documents).  This is called by sending the path /dssshowpdf.  An example of this call would be:
http://192.168.1.100/d2w-cgi-bin/D2W.dll/dssshowpdf?DOC_ID=30&ToDownload=True

Required Parameters
DOC_ID-  This commands which document the PDF will be built from.  This assumes that the PDF will be built from all of the pages that are in image format in Docs2Web.  Any non-image format documents will be skipped.

Optional Parameters
ToDownload (True or False - Default False)- This parameter when "True" directs the web user's browser to download the file and usually brings up a "Save As" dialog.  When this parameter is "False" or not used, Docs2Web returns the PDF document to the browser for viewing.  Some browsers may ignore whether the file is for download or not and always show the PDF document in the browser or in Adobe Acrobat or always show the "Save As" dialog.

NOTE: The "ToDownload" parameter controls which log event will be logged.  If the "ToDownload" parameter is set to "True", then the event will be logged under the "CanSave" right, else it will be logged under the "CanViewDocPages" right.