views:

115

answers:

2

How do I set the cookie path to "/" with the jQuery treeview plugin?

A: 

hmm, I think its may be

$.cookie('key', 'value', { path : "/" } );

Should be easy to go , :)

vernomcrp
A: 

I just reset cookie. It does not need any patches for treeview plugin

$("#tree").treeview({
         persist: "cookie",
         toggle: function (args) {
             // get cookie
             cookieId = "MycookieId";
             data = $.cookie(cookieId);
             // remove cookie
             $.cookie(cookieId, null);
             // add with path
             $.cookie(cookieId, data, { path: "/" });
         }
     });
musuk