CodeCharge Studio
search Register Login  

Web Reporting

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> PHP

 Yahoo YUI Treeview and Unordered List

Print topic Send  topic

Author Message
headhunter


Posts: 130
Posted: 08/24/2008, 1:33 PM

Hello,

does anyone already implemented the Yahoo Treeview in a page to transform a nested unordered list into a tree?

I'm a bit stuck on this one...

http://developer.yahoo.com/yui/treeview/

Thanks!
View profile  Send private message
REVENSE

Posts: 46
Posted: 10/21/2008, 6:25 AM

hai hunter,

u can use jquery.treeview its more easy to use, i think :). u only made some modification after u build menu from ccs4 builder.

here is the step :

1. build menu from menu builder and set mode to vertical tree
2. on html, include this tag javascript

<link href="jquery.treeview.css" type="text/css" rel="stylesheet">
<script src="jquery.min.js" type="text/javascript"></script>
<script src="jquery.cookie.js" type="text/javascript"></script>
<script src="jquery.treeview.js" type="text/javascript"></script>
<script src="demo.js" type="text/javascript"></script>

3. before tag /body, insert this script

<script type="text/javascript">
$(document).ready(function(){
$("#treemenu1").treeview({
collapsed: true,
animated:"normal",
persist: "location"
});

});

</script>

4. and betwen tag Div u must modify and delete some tag that ccs4 was generete, here the example

// modify class and add style or delete

<div class="MenuStyle" id="navMenuContainer" style="width:200px" >
<ul id="treemenu1" class=" filetree treeview"> // << == change

//
<!-- BEGIN Item -->
<!-- BEGIN OpenLevel -->
<ul class="level{Menu1:Item_Level}">
<!-- END OpenLevel -->

// add tag span class="file" before a href

<li {Menu1:DefaultItem}><span class="file"><a href="{ItemLink_Src}" class="{Menu1:Submenu}" target="content" title="{Menu1:Title}">{ItemLink}</a></span>

5. Finish

Note : before that use must download jquery packet :)

i hope it can help u,, before that sorry for may bad english :(


Rev



View profile  Send private message
headhunter


Posts: 130
Posted: 10/21/2008, 10:29 AM

Hi Revense,

thanks for your reply.
I should have mentioned that my problem was already solved.
I have it working now with a little modification of the treeview source file.

I'm planning to deploy a demo of my CMS soon so you can see it in action, even with icons and so on.

screenshot:


Again, thanks for the effort, it will be surely of use for someone else.

Kind regards,

Bart
View profile  Send private message
REVENSE

Posts: 46
Posted: 10/23/2008, 6:36 AM

Hai hunter, glad that u r problem was solved

btw, nice tree menu. :).

Rev
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Internet Database

Visually create Web enabled database applications in minutes.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.