23
Nov 10
Tree Menu Tutorial: How to Create Dynamic Tree Menu with Created Recordset from Dreamweaver?
Step1. Follow the visual tutorial.
Step2. Launch Sothink Tree Menu. Create a new menu item and Input ”
<%=sCatName%> in it.
Enter “Node Setting > Condition” and input the following codes in Prefix:
/*
<%
While Not Recordset1.EOF
sCatName=Recordset1.Fields.Item(“NAME”).Value
%>
*/
Then input the following codes in Suffix:
/*
<%
RecordSet1.MoveNext
Wend
%>
*/
Step3. Create a sub item for this menu item, then input
<%=sProduct%>
in it and input
<%=sLink%>
in link field.
Enter “Node Setting > Condition” and input the following codes in Prefix:
/*
<%
Recordset2.Filter = “CATID=” & Recordset1.Fields.Item(“ID”).Value
While Not RecordSet2.EOF
sProduct=Recordset2.Fields.Item(“NAME”).Value
sLink=Recordset2.Fields.Item(“LINK”).Value
%>
*/
Then input the following codes in Suffix:
/*
<%
RecordSet2.MoveNext
Wend
%>
*/
Step4. Enter “Global Setting > Web Path” to set the webpath as below:
Script path:
http;//localhost/js
Image path:
http;//localhost/image
Step5.Publish the menu to the ASP page we have just created in step1.
Now you have successfully use the created recordset from DW with Tree Menu.