roundabout
roundabout copied to clipboard
Remote loading of items [data is undefined error]
Hi
I load the the ul list I want to create the roundabout from with a $.get and then I call .roundabout({ shape: 'square' }) ... this works the first time. As soon as I want to reload the ul list a second time with different items and call roundabout agaın ... I start getting a constant error logged as "data is undefined":
Error: data is undefined Source File: js/jquery.roundabout.js Line: 734
self = $(this), data = self.data("roundabout"), [line 734] bearing = (!data.reflect) ? data.bearing % 360 : data.bearing,
sample of what Im doing:
function loadItems() { $.get("items.aspx?cid=" + $("#hdcid").val(), function(data) { $("#content").html(data); $('#main-slider ul').roundabout({ shape: 'square' }); }); }
I've been thinking about this one for a while now. I think it may be due to Roundabout already existing and then trying to re-initialize on top of old ones. Testing a couple of theories, and I should probably add a destroy method to let you clear a UL of all its Roundabout things.
Was this issue ever resolved? I'm suffering from pretty much the same thing and I don't see a destroy method in the documentation. I'm getting the error on line 747. thanks
Was this issue ever resolved?Has it added a destroy method ?
There is a method to destroy the carousel?
A similar error when re-initialize on top of old ones