|
To take advantages of Server Side Component for Tigra Menu GOLD you need to have Tigra Menu GOLD license and legally obtained client-side code of this navigation system.
|
 |
Check if your web hosting meets following requirements:
- MS Windows Hosting with SSI, ASP and Database support. If your site is hosted on linux server then see PHP version of the server side component provided in this package
- You have enough access rights to upload ASP files
|
|
In this package we've provided pre configured component so you can see it in action instantly. Copy all files and directories from current folder (asp_vb_database) to your web server.
If your hosting meets system requirements you should see demo page with menu dynamically generated from sample database when you open demo.asp file from the server via HTTP.
|
 |
|
This server side component dynamically generates hierarchy of the menu, other aspects such as styles and icons are static. Set up your Tigra Menu GOLD with static hierarchy and then migrate to dynamic source.
Should you have any product related questions you can always refer to documentation and forum.
|
 |
Code that dynamically builds structure of your navigation resides in file menu_files/items.asp provided in this package. To use this code you should link it to your ASP page with SSI (server side includes). You don't need much to know to use it, just insert code below in your ASP page:
<!-- #INCLUDE FILE="menu_files/items.asp" -->
Now you can call menu generating function anywhere below this line. Alternatively you can copy all code from menu_files/items.asp file to your ASP page. Note that you're not allowed to remove product information block that resides at the beginning of the file regardless the way you use the code.
|
 |
|
Server Side Component for Tigra Menu GOLD is able work with any ADO database, not only with MS Access.
You can adjust the script for database that your particular application uses: just call generator functions providing existing database connection (see advanced notes below in this document).
It is also possible to apply additional filters modifying SQL query in build_hierarchy function. With basic component configuration you don't need to worry about these adjustments, you can build your database based on sample MS Access database provided.
|
 |
Menu Generator Function build_hierarchy_var(...) generates client-side JavaScript code of items structure.
It should be inserted within client side JavaScript block instead of linked static menu_items.js file:
<head>
<!-- some header data -->
<link rel="stylesheet" href="menu_files/menu.css">
<script language="JavaScript" src="menu_files/menu.js"></script>
<script language="JavaScript" src="menu_files/menu_tpl.js"></script>
<script language="JavaScript">
<% Call build_hierarchy_var("MENU_ITEMS","data","table","id","ppid","caption","link") %>
</script>
</head>
function receives 7 parameters:
build_hierarchy_var(vn, dbl, tn, idfn, pidfn, cfn, lfn)
where
| vn |
Name of JavaScript variable which will contain menu hierarchy structure. Should be the same as Tigra Menu GOLD constructor receives (see below) |
String |
| dbl |
Path to Microsoft Access DB file |
String |
| tn |
Name of the table which will be used as a menu hierarchy source |
String |
| idfn |
Field name containing unique ID for each item |
String |
| pidfn |
Field name containing parent ID for each item |
String |
| cfn |
Field name containing caption for each item |
String |
| lfn |
Field name containing link for each item |
String |
|
|
 |
Check Tigra Menu GOLD constructor which should be positioned relatively in your HTML code. If in previous step you specified same menu items structure name as you used for static navigation then no changes are required here.
<script language="JavaScript">
<!--
new menu (MENU_ITEMS0, MENU_POS0);
//-->
</script>
|
|
Now upload new and updated files to your server. Make sure .asp files are in directories where scripts are allowed to run.
|
 |
If your web server is running and all above steps was passed with no errors then you should see Tigra Menu GOLD dynamically generated from your database when accessing your HTML document via HTTP.
Should you experience any problems try modifying pre configured demo step-by-step checking if code still work after each minor modification so you can detect where the error is.
|
 |
Call of the function: function build_hierarchy_var can be placed inside of the add-on script items.asp. To generate menu hierarchy structure it is enough to attach its output to HTML document:
<script language="JavaScript" src="menu_files/items.asp"></script>
Existing connection: items.asp add-on contains two functions build_hierarchy_var and build_hierarchy. First function prepares connection with the database and passes it to the second. So if you've got an already established connection you can use build_hierarchy directly.
Note: build_hierarchy function requires eight arguments to be supplied
build_hierarchy(conn, id, vn, tn, idfn, pidfn, cfn, lfn)
Below is the list of its arguments with descriptions
| conn |
ADODB.Connection object |
ADODB.Connection object |
| id |
Initial parent ID value |
Number |
| vn |
Name of JavaScript variable which will contain menu hierarchy structure |
String |
| tn |
Name of the table which will be used as a menu hierarchy source |
String |
| idfn |
Field name containing unique ID for each item |
String |
| pidfn |
Field name containing parent ID for each item |
String |
| cfn |
Field name containing caption for each item |
String |
| lfn |
Field name containing link for each item |
String |
|
|
 |
| Server Side Component for Tigra Menu GOLD is provided to Tigra Menu GOLD license owners as supplemental code at no additional charge. |
 |
As owner of the Tigra Menu GOLD license You are allowed to configure the server side component in any possible way for use in Internet (public), Intranet (corporate) or offline application, however You are strictly NOT allowed (unless specifically authorized by SoftComplex.com) to:
- Use or redistribute Server Side Component without Tigra Menu GOLD
- Claim authorship of the code
|
| Technical Support for this product is provided via Tigra Menu GOLD Forum |
 |
| Should you violate these Terms and Conditions or any other rights of SoftComplex Inc., SoftComplex Inc. reserves the right to pursue any and all legal and equitable remedies against you without limitation. |
 |