How to use OpenDocument calls without hard-coding a servername in the URL

[] [] [] [] []

Symptom
How can爐o ensure that OpenDocument URLs are portable between environments.How can to format the OpenDocument URL爏o that the server name changes with the environment?I do not want to have to hard code a server name into my links.
Reproducing the Issue
Example:
="<a href=’https://myServer:8080/OpenDocument/opendoc/openDocument.jsp?sDocName=ABC&sType=rpt&sRefresh=Y&sWindow=Y’>Click Me</a>"
In the above formula,爐he server name爄s爃ard-coded.?

Resolution
To resolve this issue and save editing time in the future, modify the URL structure to as per the following:
ORIGINAL:
="<a href=’http://myServer:8080/OpenDocument/opendoc/openDocument.jsp?sDocName=ABC&sType=rpt&sRefresh=Y&sWindow=Y’>Click Me</a>"
NEW:
="<a href=’/OpenDocument/opendoc/openDocument.jsp?sDocName=ABC&sType=rpt&sRefresh=Y&sWindow=Y’>Click Me</a>"
By dropping thehttp://myServer:8080you are forcing the browser to fill in the server name and port that it is already connected to.?This will eliminate the need to specify the server.
Note, for XI Release 2, the URL to OpenDocument is different.?Please refer to the documentation to determine the appropriate path to the openDocument.jsp.

Keywords
opendocument.jsp, opendocument, open document, hard code, hardcode, hard-code, server, URL, report, linking, how to, opendoc

[Slashdot] [Digg] [Reddit] [del.icio.us] [Facebook] [Technorati] [Google] [StumbleUpon]

Leave a Comment