Provides instructions on setting up and using the LaunchPad Web-based LeasePak menu.
This document assumes you have a working knowledge of CSS, HTML, JavaScript, XML, and XSLT. Contact your NetSol representative for more information.
The file report_path_fn.xsl contains the template fn_get_rpt_path
, which specifies the path to the XSL style sheet directory. This file is not installed with the LeasePak client software. Instead, LeasePak creates it using the following process:
Each time a user logs on to the LeasePak client, LeasePak verifies that the report_path_fn.xsl file exists and that the location it specifies matches the location established through the Custom General setup. If you are customizing the XSL style sheet location, NetSol recommends allowing all users write access to that location until you have determined and configured your XSL style sheet location. Once your setup is complete, you can restrict write access to the XSL style sheet location.
By default, the location of the XSL style sheets, and therefore the location specified in report_path_fn.xsl, is install_path\Report Templates, where install_path is the installed location of the LeasePak client software on each user's computer. The following sections describe situations in which you may need to change the XSL style sheet location. If you need to do this, you will also need to specify the new location using Custom General [U0712] (refer to XSL Style Sheet Location Customization for instructions).
To use the stored procedures and style sheets that LeasePak provides--without customizations--the administrative user (such as lpadmin
) or LeasePak client software installer must:
The administrative user can change the XSL style sheet location using Custom General [U0712]: Miscellaneous Customizations. See XSL Style Sheet Location Customization for instructions.
You must also provide users needing access to LaunchPad with a start point XSL style sheet. This is the style sheet LeasePak uses to perform the initial data generation and transformation when the user logs on to LeasePak and displays the LaunchPad menu. Refer to the section LaunchPad "Start Point" Customization for instructions.
If you are customizing any of the style sheets or scripts LeasePak provides or creating your own, do not use the default install_path\Report Templates location, otherwise future LeasePak client installations may overwrite your customizations. Instead, NetSol recommends one of the following options based on your business needs:
Place the contents (style sheet files, as well as css, html, images, scripts, and xml subdirectories and files) in one central location, such as a directory under a shared network drive. This solution works well for the following conditions:
Place different sets of contents in two or more different locations that all users map as the same location. For example, a set of style sheets, etc. with French text resides on \\français\data, while a set of style style sheets with English text resides on \\english\data. Some users map drive M: to point to \\français, while others map the same drive M: to point to \\english. You configure the XSL style sheet location as M:\data\ in Custom General. This solution works well for the following conditions:
The administrative user can change the designated XSL style sheet location using Custom General [U0712]: Miscellaneous Customizations. See XSL Style Sheet Location Customization for instructions.
You must also provide users needing access to LaunchPad with a start point XSL style sheet. This is the style sheet LeasePak uses to perform the initial data generation and transformation when the user logs on to LeasePak and displays the LaunchPad menu. Refer to the section LaunchPad "Start Point" Customization for instructions.
Use Custom General [U0712]: Miscellaneous Customizations to customize the XSL style sheet location.
You must exit LeasePak and log back on to finish setting this parameter.
Do not attempt to modify
report_path_fn.xsl directly. Each time you log in, LeasePak checks the file against the value from Custom General, displays an error message if they do not match, and overwrites report_path_fn.xsl with the value set in LeasePak.
The following diagram illustrates the initial process of setting up and generating the LaunchPad menu.
An administrative user must set up both the global location for all XSL style sheets and the LaunchPad "start point"--the starting style sheet for LaunchPad--for each user accessing LaunchPad. Then, the user or an administrative user must set up the items that will appear in the LaunchPad menu. Finally, when the user logs on to the LeasePak client, LeasePak generates the XML that LeasePak then transforms using the XSL "start point" style sheet specified for the user. What happens after the initial data generation and transformation depends on the design of the starting style sheet--by controlling what links appear on this sheet, you control what the user is able to subsequently access.
LeasePak provides the following components that you can use as building blocks for your LaunchPad customizations:
Users needing access to LaunchPad must have read access to the XSL style sheet location.
To specify the path of this and other XSL style sheets, use the field XSL Report Templates in Custom General [U0712]: Miscellaneous Customizations.
You must complete the setup for LaunchPad before you can customize the menu.
To customize the LaunchPad menu, from the LeasePak main menu select Window, LaunchPad, Menu Customizations. LeasePak displays the menu customization screen:
This is a modal window, meaning that you must close this window by clicking either OK or Cancel before you can access any other updates or reports in LeasePak.
To add menu items to the list, click Insert, then follow the instructions below specific to the type of item you are adding.
To change an item already in the list, click the item to highlight it, then refer to the specific instructions in the sections below.
To delete an item from the list, click the item to highlight it, then click Delete.
Click OK to save changes to the menu list or Cancel to exit the LaunchPad Menu Customization without making any changes.
You must add at least one LP Menu Request, Web/URL, or SQL Request menu item before you can add a group.
To add a Group item to the menu list:
To add a LP Menu Request item to the menu list:
To add a Web/URL item to the menu list:
The SQL Request option in the LaunchPad Menu Customization allows you to include links on the LaunchPad menu page that provide additional customized reports, such as a listing of the user's unprocessed notes or a listing of applications ready for booking. For each of these links, LeasePak executes a specified SQL stored procedure on the LeasePak server to retrieve the desired information, transforms the output XML using a specified XSL style sheet, and displays the HTML results for the user.
To include SQL Request items in your LaunchPad menu, you must complete additional setup requirements:
LeasePak includes a sample lp_sqlreq.xml file in the install_path\Report Templates\samples\SQL Request directory:
<?xml version="1.0"?> <lp_sqlreq> <sqlreq caption="High Priority Notes" xsl_file="misc_mjl_info.xsl" stored_proc="up_mjl_info"></sqlreq> <sqlreq caption="New Lease Bookings" xsl_file="misc_new_lse_book.xsl" stored_proc="up_new_lse_book"></sqlreq> </lp_sqlreq>
In the first <sqlreq> element, "High Priority Notes" is the text that will appear for the link on the menu, "misc_mjl_info.xsl" is the style sheet, and "up_mjl_info" is the stored procedure. For your custom SQL requests, you will need to create the XSL style sheet and SQL stored procedure, install these in the appropriate locations, create a lp_sqlreq.xml file with one <sqlreq> element for each XSL style sheet/SQL stored procedure combination, and install the lp_sqlreq.xml file in the install_path\Report Templates\xml directory.
Once you have completed the setup requirements, you can select the SQL Request option in the LaunchPad Menu Customization, and clicking on
displays a list of available SQL Request items from which you can choose:
To add an SQL Request item to the menu list:
For more information on using XSL style sheets and SQL stored procedures with LeasePak XSLT Customizations, refer to XSLT Customizations: Lease Summary.
SQL stored procedures for use with SQL Request or SQL Request Startup cannot take passed-in parameters at this time. Contact your NetSol representative for more information.
In addition to including SQL Request items on the LaunchPad menu page, you can also set LeasePak to run one or more XSL template/SQL stored procedure combinations when the user starts the LaunchPad menu page. This provides the user with an immediate display of additional customized information, such as a listing of customer accounts requiring immediate attention, incorporated into a LaunchPad page.
LeasePak includes sample files for setting this up in the install_path\Report Templates\samples\SQL Request StartUp directory. The XML file lp_sqlreq_su.xml specifies which stored procedures to run when LaunchPad starts:
<?xml version="1.0"?> <lp_sqlreq_su> <sqlreq xml_file="noteinfo.xml" stored_proc="up_mjl_info"></sqlreq> </lp_sqlreq_su>
In the <sqlreq> element:
For each <sqlreq> element you will also need to create an XSL template to match to the XML parent element name. This template can either be placed on the lp_launchpad.xsl stylesheet or on another stylesheet that lp_launchpad.xsl includes. In the SQL Request Startup sample files, the template matching the noteinfo parent element is on lp_notes.xsl, which lp_launchpad.xsl includes.
To use the files in the sample SQL Request Startup:
For more information on using XSL style sheets and SQL stored procedures with LeasePak XSLT Customizations, refer to XSLT Customizations: Lease Summary.
SQL stored procedures for use with SQL Request or SQL Request Startup cannot take passed-in parameters at this time. Contact your NetSol representative for more information.
You must set up LaunchPad before you can use it.
Here is an example of a menu customization:
To see the resulting menu, click OK. From the LeasePak main menu, select Window, LaunchPad, Show LaunchPad. The program displays a full-screen Web page menu based on your customizations (screen size is reduced to fit the image in the document):
Each item in the menu is a link. Clicking on the item Market Rates launches a browser window displaying the Web page (in this case, market rates from http://www.bloomberg.com/markets/rates). Clicking on the item Application displays the menu choices in the Application group--New Normal, Assets, and Status Transfer. Clicking on one of the items in the group launches the Application Tracking [U08] update for that item.
To close the LaunchPad menu page, from the LeasePak main menu select Window, LaunchPad, Hide LaunchPad.
By default, the XSL style sheets for LaunchPad are located in install_path\Report Templates, where install_path is the installed location of the LeasePak client software on each user's computer. You can instead place a single set of the contents of this directory (including subdirectories and files) in a centralized location, then specify that location in Custom General [U0712]. Refer to the LeasePak Setup section for more information.
LeasePak provides the XSL style sheet lp_launchpad.xsl, which in turn includes several other style sheets used to generate the LaunchPad menu. All of these style sheets can be customized to change the way they display menu items, to change how they interact with each other, and to include new style sheets and functions.
fn_get_rpt_path
that specifies the path to the XSL style
sheet directory. Refer to the section LeasePak Setup for more information.The functions that the user accesses to include pop-up windows in templates are located in scripts_fn.xsl.
The stylesheet lp_launchpad_fn.xsl includes the stylesheet scripts_fn.xsl. In turn, scripts_fn.xsl includes the major function templates that retrieve data and access LeasePak menu items, as well as several formatting function templates.
LaunchPad is set up to allow the user (or administrative user) to customize most style sheets, templates, and scripts as needed. If you require changes in the way any of the function templates work, or if you need additional functions, you can use the functions provided in scripts_fn.xsl as a starting point for your customizations. However, NetSol recommends that you save a copy of the style sheets, templates, and scripts as they were installed with the client software in case you need to restore a customized template or script to its original state.
The function templates in scripts_fn.xsl fall into two main categories--those that call scripts (JavaScript and/or JScript), indicated in the following listing by Calls script(s): Yes, and those that do not call scripts, indicated in the following listing by Calls script(s): No. When customizing function templates that call scripts, you may also need to modify the scripts. For function templates that do not call scripts, you only need to consider the content of the template itself. Contact your NetSol representative for more information.
Standard LaunchPad functionality, as provided in the LeasePak software, does not make use of all the function templates in scripts_fn.xsl, and when it is using a function, may not always use all of the parameters available for that function.
The primary scripts_fn.xsl function templates that LaunchPad uses (the default as provided in the LeasePak software) are fn_lp_menu_request
and
fn_http_sql_request
.
You can, however, modify LaunchPad to use additional functions from scripts_fn.xsl, as well as your own custom functions.
Location: scripts_fn.xsl
Calls script(s): Yes
This template, when applied to column headers in a table, makes the table sortable on any selected column.
The template takes the incoming parameters and passes them to the JavaScript function SortColumn
, which sorts the table on the selected column.
Call the template from the <th>
column header of a table:
<th width="70" rowspan="2" align="right" class="colhdr"> <xsl:call-template name="fn_sort_column"> <xsl:with-param name="column_hdr">Invoice#\nCredit Memo</xsl:with-param> <xsl:with-param name="class">colhdr</xsl:with-param> <xsl:with-param name="column">0</xsl:with-param> </xsl:call-template> </th>
Parameters:
Function template from scripts_fn.xsl:
<!-- ================================ --> <!-- Function to make column sortable --> <!-- ================================ --> <xsl:template name="fn_sort_column"> <xsl:param name="column_hdr"></xsl:param> <xsl:param name="class"></xsl:param> <xsl:param name="column"></xsl:param> <SCRIPT LANGUAGE="JavaScript"> SortColumn("<xsl:value-of select="$column_hdr"/>", "<xsl:value-of select="$class"/>", "<xsl:value-of select="$column"/>"); </SCRIPT> </xsl:template>
Location: scripts_fn.xsl
Calls script(s): Yes
This template calls scripts that work with LeasePak to make one of the following requests:
data
parameterdata
parameterdata
parameterdata
parameterdata
parameterThis template differs from fn_lp_menu_request
, not only with its restricted list of options, but also in that each of these options is guaranteed to bypass the initial selection criteria screens for the report, as long as you supply a valid data parameter.
The template takes the incoming parameters and passes them to the JavaScript function HTTPRequest
, which in turn calls a corresponding JScript function that processes the request.
Call the function from any part of a template used to display text:
<td> <xsl:call-template name="fn_http_request"> <xsl:with-param name="service">R0404</xsl:with-param> <xsl:with-param name="xsl_file">R0404</xsl:with-param> <xsl:with-param name="hover_value">A/R Balancing</xsl:with-param> <xsl:with-param name="display_value"><xsl:value-of select="tot_amt_d"/></xsl:with-param> <xsl:with-param name="class">dl_td_url</xsl:with-param> <xsl:with-param name="data"><xsl:value-of select='lse_s'/></xsl:with-param> <xsl:with-param name="new_window">True</xsl:with-param> </xsl:call-template> </td>
Parameters:
Function template from scripts_fn.xsl:
<!-- ============================= --> <!-- Function to make HTTP request --> <!-- ============================= --> <xsl:template name="fn_http_request"> <xsl:param name="xsl_file"></xsl:param> <xsl:param name="display_value"></xsl:param> <xsl:param name="class"></xsl:param> <xsl:param name="hover_value"></xsl:param> <xsl:param name="service"></xsl:param> <xsl:param name="data"></xsl:param> <xsl:param name="new_window"></xsl:param> <SCRIPT LANGUAGE="JavaScript"> HTTPRequest("<xsl:value-of select="$service"/>", "<xsl:value-of select="$xsl_file"/>", "<xsl:value-of select="$display_value"/>", "<xsl:value-of select="$class"/>", "<xsl:value-of select="$hover_value"/>", "<xsl:value-of select="$data"/>", "<xsl:value-of select="$new_window"/>"); </SCRIPT> </xsl:template>
Location: scripts_fn.xsl
Calls script(s): Yes
This function template calls scripts that work with LeasePak to run the specified stored procedure, transform the XML output with the specified XSL style sheet, and display the results.
The template takes the incoming parameters and passes them to the JavaScript function HTTPRequest
, which in turn calls a corresponding JScript function that processes the request.
Call the function from any part of a template used to display text:
<td colspan="1" class="dl_td" align="right"> <xsl:call-template name="fn_http_sql_request"> <xsl:with-param name="xsl_file">misc_rgc_info</xsl:with-param> <xsl:with-param name="hover_value">List of CoLessee/Guarantors/User-defined clients ...</xsl:with-param> <xsl:with-param name="display_value">Yes</xsl:with-param> <xsl:with-param name="class">dl_td_url</xsl:with-param> <xsl:with-param name="stored_proc">cp_rgc_info</xsl:with-param> <xsl:with-param name="data0"><xsl:value-of select='lse_s'/></xsl:with-param> <xsl:with-param name="new_window">True</xsl:with-param> </xsl:call-template> </td>
Parameters:
Function template from scripts_fn.xsl:
<!-- ===================================== --> <!-- Function to make HTTP Sql Qry request --> <!-- ===================================== --> <xsl:template name="fn_http_sql_request"> <xsl:param name="xsl_file"></xsl:param> <xsl:param name="display_value"></xsl:param> <xsl:param name="class"></xsl:param> <xsl:param name="hover_value"></xsl:param> <xsl:param name="new_window"></xsl:param> <xsl:param name="stored_proc"></xsl:param> <xsl:param name="data0"></xsl:param> <xsl:param name="data1"></xsl:param> <xsl:param name="data2"></xsl:param> <xsl:param name="data3"></xsl:param> <xsl:param name="data4"></xsl:param> <xsl:variable name="spdata"> <xsl:value-of select="concat('<sp_name>', $stored_proc, '</sp_name>', '<param0>', $data0, '</param0>', '<param1>', $data1, '</param1>', '<param2>', $data2, '</param2>', '<param3>', $data3, '</param3>', '<param4>', $data4, '</param4>')"/> </xsl:variable> <SCRIPT LANGUAGE="JavaScript"> HTTPRequest("sql_qry", "<xsl:value-of select="$xsl_file"/>", "<xsl:value-of select="$display_value"/>", "<xsl:value-of select="$class"/>", "<xsl:value-of select="$hover_value"/>", "<xsl:value-of select="$spdata"/>", "<xsl:value-of select="$new_window"/>"); </SCRIPT> </xsl:template>
Location: scripts_fn.xsl
Calls script(s): Yes
This function template calls scripts that work with LeasePak to take an existing specified XML data file, transform it using the specified XSL style sheet, and display the results. The template takes the incoming parameters and passes them to the JavaScript function XMLXSLTransform
, which in turn calls a corresponding JScript function that processes the request.
Call the function from any part of a template used to display text:
<xsl:call-template name="fn_xmlxsl_transform"> <xsl:with-param name="xml_file">xml_file</xsl:with-param> <xsl:with-param name="xsl_file">xsl_file</xsl:with-param> <xsl:with-param name="display_value">display_value</xsl:with-param> <xsl:with-param name="hover_value">hover_value</xsl:with-param> <xsl:with-param name="class">class</xsl:with-param> <xsl:with-param name="new_window">new_window</xsl:with-param> </xsl:call-template>
The template fn_xmlxsl_transform
takes the following parameters:
Function template from scripts_fn.xsl:
<!-- ============================================================================ --> <!-- Function to take an existing XML and XSL document to create an HTML document --> <!-- ============================================================================ --> <xsl:template name="fn_xmlxsl_transform"> <xsl:param name="xml_file"></xsl:param> <xsl:param name="xsl_file"></xsl:param> <xsl:param name="display_value"></xsl:param> <xsl:param name="class"></xsl:param> <xsl:param name="hover_value"></xsl:param> <xsl:param name="new_window"></xsl:param> <SCRIPT LANGUAGE="JavaScript"> XMLXSLTransform("<xsl:value-of select="$xml_file"/>", "<xsl:value-of select="$xsl_file"/>", "<xsl:value-of select="$display_value"/>", "<xsl:value-of select="$class"/>", "<xsl:value-of select="$hover_value"/>", "<xsl:value-of select="$new_window"/>"); </SCRIPT> </xsl:template>
Location: scripts_fn.xsl
Calls script(s): Yes
This function template calls scripts that work with LeasePak to access any of the LeasePak
Menu Options. Many of the style sheets that LeasePak provides feature calls to
fn_lp_menu_request
, providing links that access LeasePak reports or updates.
As with the other request-type templates, fn_lp_menu_request
takes the incoming parameters and passes them to the JavaScript function
LPMenuReq
, which in turn calls a corresponding JScript function that processes the request.
This template differs from fn_http_request
in that while it provides a comprehensive list of LeasePak menu options, bypassing the initial selection criteria screens varies from option to option, even when you supply valid parameters.
Call the function from any part of a template used to display text:
<td> <xsl:call-template name="fn_lp_menu_request"> <xsl:with-param name="menu">U0210</xsl:with-param> <xsl:with-param name="display_value"><xsl:text disable-output-escaping="yes"><![CDATA[» ]]></xsl:text>Change</xsl:with-param> <xsl:with-param name="hover_value">U0210 Asset update...</xsl:with-param> <xsl:with-param name="asset"><xsl:value-of select="unit_s"/></xsl:with-param> <xsl:with-param name="class">dl_th_url</xsl:with-param> </xsl:call-template> </td>
The above example shows only a few of the parameters available when calling this template. The parameters that apply to a menu request will vary by menu item and current data available. The full list of parameters includes:
For any given menu request, you should only use the parameters appropriate to the report or update. Unlike with
fn_http_request
, supplying parameters does not guarantee you will bypass the initial selection criteria screens.
Your ability to use parameters to bypass these screens will vary from option to option.
Function template from scripts_fn.xsl:
<!-- ===================================== --> <!-- Function to make LP Menu request --> <!-- ===================================== --> <xsl:template name="fn_lp_menu_request"> <xsl:param name="menu"></xsl:param> <xsl:param name="display_value"></xsl:param> <xsl:param name="class"></xsl:param> <xsl:param name="hover_value"></xsl:param> <xsl:param name="application"></xsl:param> <xsl:param name="asset"></xsl:param> <xsl:param name="batchnum"></xsl:param> <xsl:param name="broker"></xsl:param> <xsl:param name="customer"></xsl:param> <xsl:param name="group"></xsl:param> <xsl:param name="guarantor"></xsl:param> <xsl:param name="investor"></xsl:param> <xsl:param name="invoice"></xsl:param> <xsl:param name="lease"></xsl:param> <xsl:param name="lender"></xsl:param> <xsl:param name="lessee"></xsl:param> <xsl:param name="misc"></xsl:param> <xsl:param name="notebook"></xsl:param> <xsl:param name="vendor"></xsl:param> <SCRIPT LANGUAGE="JavaScript"> LPMenuReq("<xsl:value-of select="$menu"/>", "<xsl:value-of select="$display_value"/>", "<xsl:value-of select="$class"/>", "<xsl:value-of select="$hover_value"/>", "<xsl:value-of select="$application"/>", "<xsl:value-of select="$asset"/>", "<xsl:value-of select="$batchnum"/>","<xsl:value-of select="$broker"/>", "<xsl:value-of select="$customer"/>", "<xsl:value-of select="$group"/>", "<xsl:value-of select="$guarantor"/>", "<xsl:value-of select="$investor"/>", "<xsl:value-of select="$invoice"/>", "<xsl:value-of select="$lease"/>", "<xsl:value-of select="$lender"/>", "<xsl:value-of select="$lessee"/>", "<xsl:value-of select="$misc"/>", "<xsl:value-of select="$notebook"/>", "<xsl:value-of select="$vendor"/>"); </SCRIPT> </xsl:template>
Location: scripts_fn.xsl
Calls script(s): Yes
These four function templates take the passed parameters and call their corresponding scripts (LPPopupRight
, LPPopupLeft
,
LPPopupRightTopWB
, LPPopupLeftTopWB
) to launch a popup window when the user positions the mouse pointer over the display image or text:
fn_popup_r
, except that it handles cases in which
the display image or text is near the top of the Web page, where a normal popup window might be partially hidden.fn_popup_l
, except that it handles cases in which
the display image or text is near the top of the Web page, where a normal popup window might be partially hidden.These functions work in conjunction with mouse-over and mouse-out events--that is, the popup window appears when the user positions
the mouse pointer over the display image or text and disappears when the user moves the pointer off the display item. These functions already include the
handling of the mouse-over and mouse-out events; using event attributes such as onmouseover
and onmouseout
within the tag from which
you are calling a popup function will have unexpected and erroneous results.
Call these functions from any part of a template used to display text:
<td colspan="4" class="dl_td" align="right"> <!-- S T A R T --> <!-- Give the user the ability to display a popup window containing the RED FLAG WARNING --> <xsl:choose> <xsl:when test="les_rfw_note_s != ''"> <xsl:call-template name="fn_popup_l_twb"> <xsl:with-param name="class">dl_td_url</xsl:with-param> <xsl:with-param name="image">rfw.gif</xsl:with-param> <xsl:with-param name="image_align">right</xsl:with-param> <xsl:with-param name="popup_title">Red Flag Warning for Lessee</xsl:with-param> <xsl:with-param name="display_value"></xsl:with-param> <xsl:with-param name="inner_html"> <xsl:text disable-output-escaping="yes"><![CDATA[<p><b>Message:</b> ]]></xsl:text> <xsl:value-of select='les_rfw_note_s'/> <xsl:text disable-output-escaping="yes"><![CDATA[</p>]]></xsl:text> </xsl:with-param> </xsl:call-template> </xsl:when> <xsl:otherwise>None</xsl:otherwise> </xsl:choose> <!-- F I N I S H --> </td>
Parameters (same for all popup functions):
<xsl:param name="display_value"><xsl:value-of select='element_name' /></xsl:param>
<xsl:param name="display_value">$previously_defined_variable</xsl:param>
<xsl:param name="display_value">Static Text</xsl:param>
align
attribute value to apply to the image parameter.
Recommended if you are using display_value and image together.class
attribute value to apply to the display_value and/or
image parameters.disable-output-escaping="yes"
with CDATA notation to provide
formatting for the inner HTML.The parameters display_value, image, image_align, class, and url all apply to the content and appearance of the display the user positions the mouse over to trigger the popup window. The parameters popup_title and inner_html apply to the content and appearance of the popup window itself.
Popup function templates from scripts_fn.xsl:
<!-- ============================================================================== --> <!-- Function to make a POPUP window display to the right of the display text/image --> <!-- ============================================================================== --> <xsl:template name="fn_popup_r"> <xsl:param name="display_value"></xsl:param> <xsl:param name="image"></xsl:param> <xsl:param name="image_align"></xsl:param> <xsl:param name="class"></xsl:param> <xsl:param name="url"></xsl:param> <xsl:param name="popup_title"></xsl:param> <xsl:param name="inner_html"></xsl:param> <SCRIPT LANGUAGE="JavaScript"> LPPopupRight("<xsl:value-of select="$display_value"/>", "<xsl:value-of select="$class"/>", "<xsl:value-of select="$url"/>", "<xsl:value-of select="$image"/>", "<xsl:value-of select="$image_align"/>", "<xsl:value-of select="$popup_title"/>", "<xsl:value-of select="$inner_html"/>"); </SCRIPT> </xsl:template>
<!-- ============================================================================= --> <!-- Function to make a POPUP window display to the left of the display text/image --> <!-- ============================================================================= --> <xsl:template name="fn_popup_l"> <xsl:param name="display_value"></xsl:param> <xsl:param name="image"></xsl:param> <xsl:param name="image_align"></xsl:param> <xsl:param name="class"></xsl:param> <xsl:param name="url"></xsl:param> <xsl:param name="popup_title"></xsl:param> <xsl:param name="inner_html"></xsl:param> <SCRIPT LANGUAGE="JavaScript"> LPPopupLeft("<xsl:value-of select="$display_value"/>", "<xsl:value-of select="$class"/>", "<xsl:value-of select="$url"/>", "<xsl:value-of select="$image"/>", "<xsl:value-of select="$image_align"/>", "<xsl:value-of select="$popup_title"/>", "<xsl:value-of select="$inner_html"/>"); </SCRIPT> </xsl:template>
<!-- ============================================================================== --> <!-- Function to make a POPUP window display to the right of the display text/image --> <!-- Used for items near the top of the web browser when the normal popup --> <!-- window is partially hidden. --> <!-- ============================================================================== --> <xsl:template name="fn_popup_r_twb"> <xsl:param name="display_value"></xsl:param> <xsl:param name="image"></xsl:param> <xsl:param name="image_align"></xsl:param> <xsl:param name="class"></xsl:param> <xsl:param name="url"></xsl:param> <xsl:param name="popup_title"></xsl:param> <xsl:param name="inner_html"></xsl:param> <SCRIPT LANGUAGE="JavaScript"> LPPopupRightTopWB("<xsl:value-of select="$display_value"/>", "<xsl:value-of select="$class"/>", "<xsl:value-of select="$url"/>", "<xsl:value-of select="$image"/>", "<xsl:value-of select="$image_align"/>", "<xsl:value-of select="$popup_title"/>", "<xsl:value-of select="$inner_html"/>"); </SCRIPT> </xsl:template>
<!-- ============================================================================= --> <!-- Function to make a POPUP window display to the left of the display text/image --> <!-- Used for items near the top of the web browser when the normal popup --> <!-- window is partially hidden. --> <!-- ============================================================================= --> <xsl:template name="fn_popup_l_twb"> <xsl:param name="display_value"></xsl:param> <xsl:param name="image"></xsl:param> <xsl:param name="image_align"></xsl:param> <xsl:param name="class"></xsl:param> <xsl:param name="url"></xsl:param> <xsl:param name="popup_title"></xsl:param> <xsl:param name="inner_html"></xsl:param> <SCRIPT LANGUAGE="JavaScript"> LPPopupLeftTopWB("<xsl:value-of select="$display_value"/>", "<xsl:value-of select="$class"/>", "<xsl:value-of select="$url"/>", "<xsl:value-of select="$image"/>", "<xsl:value-of select="$image_align"/>", "<xsl:value-of select="$popup_title"/>", "<xsl:value-of select="$inner_html"/>"); </SCRIPT> </xsl:template>
Location: scripts_fn.xsl
Calls script(s): No
This function template takes a parameter of a 10-digit phone number and formats it as (nnn) nnn-nnnn. If the number passed to the function is not 10 digits, the function returns the number unchanged.
Call the function from any part of a template used to display text:
<p> <xsl:call-template name="fn_format_phone_num"> <xsl:param name="phone">phone</xsl:param> </xsl:call-template> </p>
Parameters:
Function template from scripts_fn.xsl:
<!-- ===================================== --> <!-- Function to format a phone number --> <!-- ===================================== --> <xsl:template name="fn_format_phone_num"> <xsl:param name="phone"></xsl:param> <xsl:choose> <xsl:when test="string-length($phone) = 10"> (<xsl:value-of select="substring($phone,1,3)"/>) <xsl:value-of select="substring($phone,4,3)"/>-<xsl:value-of select="substring($phone,6,4)"/> </xsl:when> <xsl:otherwise> <xsl:value-of select="$phone"/> </xsl:otherwise> </xsl:choose> </xsl:template>
Location: scripts_fn.xsl
Calls script(s): No
This function template takes a parameter of a 9-digit US zip code and formats it as nnnnn-nnnn. If the postal code passed to the function is not 9 digits, the function returns the postal code unchanged.
Call the function from any part of a template used to display text:
<p> <xsl:call-template name="fn_format_zip_code"> <xsl:param name="zipcode">zipcode</xsl:param> </xsl:call-template> </p>
Parameters:
Function template from scripts_fn.xsl:
<!-- ===================================== --> <!-- Function to format a zip code --> <!-- ===================================== --> <xsl:template name="fn_format_zip_code"> <xsl:param name="zipcode"></xsl:param> <xsl:choose> <xsl:when test="string-length($zipcode) = 9"> <xsl:value-of select="substring($zipcode,1,5)"/>-<xsl:value-of select="substring($zipcode,6,4)"/> </xsl:when> <xsl:otherwise> <xsl:value-of select="$zipcode"/> </xsl:otherwise> </xsl:choose> </xsl:template>
Location: scripts_fn.xsl
Calls script(s): No
This function template takes a parameter of a 9-digit Social Security Number (SSN) and formats it as nnn-nn-nnnn. If the number passed to the function is not 9 digits, the function returns the number unchanged.
Call the function from any part of a template used to display text:
<p> <xsl:call-template name="fn_format_ssn_num"> <xsl:param name="ssn">ssn</xsl:param> </xsl:call-template> </p>
Parameters:
Function template from scripts_fn.xsl:
<!-- ===================================== --> <!-- Function to format a SSN number --> <!-- ===================================== --> <xsl:template name="fn_format_ssn_num"> <xsl:param name="ssn"></xsl:param> <xsl:choose> <xsl:when test="string-length($ssn) = 9"> <xsl:value-of select="substring($ssn,1,3)"/>-<xsl:value-of select="substring($ssn,4,2)"/>-<xsl:value-of select="substring($ssn,6,4)"/> </xsl:when> <xsl:otherwise> <xsl:value-of select="$ssn"/> </xsl:otherwise> </xsl:choose> </xsl:template>
Location: scripts_fn.xsl
Calls script(s): No
This function template takes a parameter of a number in a standard US decimal format and converts it to a US currency format, placing negative amounts in parentheses.
The incoming number can use one or more commas for thousands separators. The incoming number must use a period for the decimal separator if the number includes a cents component--that is, $150.25 must be passed in as 150.25, not 15025.
Call the function from any part of a template used to display text:
<p> <xsl:call-template name="fn_format_amount"> <xsl:param name="amount">amount</xsl:param> </xsl:call-template> </p>
Parameters:
Function template from scripts_fn.xsl:
<!-- ===================================== --> <!-- Function to format an amount --> <!-- ===================================== --> <xsl:template name="fn_format_amount"> <xsl:param name="amount"></xsl:param> <xsl:value-of select="format-number(translate($amount, ',', ''),'$###,###,###,###,##0.00;($###,###,###,###,##0.00)')"/> </xsl:template>
Location: scripts_fn.xsl
Calls script(s): No
This function template takes a parameter of a date in MM/DD/YY format and transforms the date into a YYYYMMDD format, using the logic that 2-digit years < 50 are preceded by the century 20, while 2-digit years >= 50 are preceded by 19.
Call the function from any part of a template used to display text:
<p> <xsl:call-template name="fn_format_date_yyyymmdd"> <xsl:param name="date">date</xsl:param> </xsl:call-template> </p>
Parameters:
Function template from scripts_fn.xsl:
<!-- ================================================================= --> <!-- Function to format a date in MM/DD/YY format to a YYYYMMDD format --> <!-- ================================================================= --> <xsl:template name="fn_format_date_yyyymmdd"> <xsl:param name="date"></xsl:param> <xsl:variable name="new_date"> <xsl:value-of select="translate($date, '-', '/')"/> </xsl:variable> <!-- Year --> <xsl:variable name="year"> <xsl:value-of select="substring-after(substring-after($new_date, '/'), '/')"/> </xsl:variable> <!-- Month --> <xsl:variable name="mon"> <xsl:value-of select="format-number(number(substring-before($new_date, '/')), '00')"/> </xsl:variable> <!-- Day --> <xsl:variable name="day"> <xsl:value-of select="format-number(number(substring-before(substring-after($new_date, '/'), '/')), '00')"/> </xsl:variable> <!-- Get the century based upon year --> <xsl:variable name="cent"> <xsl:choose> <xsl:when test="$year < '50'">20</xsl:when> <xsl:otherwise>19</xsl:otherwise> </xsl:choose> </xsl:variable> <!-- Now build our date in the YYYYMMDD format --> <xsl:value-of select="$cent"/><xsl:value-of select="$year"/><xsl:value-of select="$mon"/><xsl:value-of select="$day"/> </xsl:template>
LeasePak Documentation Suite
©
2006 by NetSol Technologies Inc. All rights reserved.
The information contained in this document is the property of NetSol Technologies Inc. Use of the information contained herein is restricted. Conditions of use are subject to change without notice. NetSol Technologies Inc. assumes no liability for any inaccuracy that may appear in this document; the contents of this document do not constitute a promise or warranty. The software described in this document is furnished under license and may be used or copied only in accordance with the terms of said license. Unauthorized use, alteration, or reproduction of this document without the written consent of NetSol Technologies Inc. is prohibited.
This message should disappear within 5-15 seconds, depending on the size of the document and the speed of your connection to the Documentation Suite.
If you can still see this message after 20 seconds, try clicking the Refresh or Reload button on your Web browser.
If your document still does not load, refer to Document Load Troubleshooting for instructions on how to fix possible problems with either your Documentation Suite installation or Web browser setup.
If you do not have read access to the parent docsuite directory, you will not be able to load the Document Load Troubleshooting document. In this case, contact your network administrator for assistance.