Skip to content

JSON w/ simple image, duplicate data on reload #40

@jimklonowski

Description

@jimklonowski

I'm trying to use the JSON loader with a SimpleImageController in an asp.net site, but when I reload the page, I'm ending up with multiple instances of the pivotviewer on the same #pivotviewer div.

Example image: http://i.imgur.com/VzItlbx.png

I'm starting the viewer like so:

            $(document).ready(function () {
                $('#pivotviewer').PivotViewer(
                    {
                        Loader: new PivotViewer.Models.Loaders.JSONLoader("vehicles.json"),
                        ImageController: new PivotViewer.Views.SimpleImageController()
                    }
                );
            });

Is there a proper way to destroy any existing instances of the html5pivotviewer and its data on a DOM element or page before attaching a new?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions