{"action":"created","issue":{"url":"https://api.github.com/repos/webcreate/infinite-ajax-scroll/issues/209","labels_url":"https://api.github.com/repos/webcreate/infinite-ajax-scroll/issues/209/labels{/name}","comments_url":"https://api.github.com/repos/webcreate/infinite-ajax-scroll/issues/209/comments","events_url":"https://api.github.com/repos/webcreate/infinite-ajax-scroll/issues/209/events","html_url":"https://github.com/webcreate/infinite-ajax-scroll/issues/209","id":95993153,"number":209,"title":"Previous functions break on new page","user":{"login":"adambirdie","id":2778835,"avatar_url":"https://avatars.githubusercontent.com/u/2778835?v=3","gravatar_id":"","url":"https://api.github.com/users/adambirdie","html_url":"https://github.com/adambirdie","followers_url":"https://api.github.com/users/adambirdie/followers","following_url":"https://api.github.com/users/adambirdie/following{/other_user}","gists_url":"https://api.github.com/users/adambirdie/gists{/gist_id}","starred_url":"https://api.github.com/users/adambirdie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adambirdie/subscriptions","organizations_url":"https://api.github.com/users/adambirdie/orgs","repos_url":"https://api.github.com/users/adambirdie/repos","events_url":"https://api.github.com/users/adambirdie/events{/privacy}","received_events_url":"https://api.github.com/users/adambirdie/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-07-20T05:56:06Z","updated_at":"2015-07-21T08:45:19Z","closed_at":"2015-07-20T17:17:14Z","body":"When my page loads my ajax functions work perfectly, but when a new page loads that previous page events stop working? I am reinitialising them on new page load for the new its which I presumed was correct? I am sure there is something simple I am missing but cannot see it here is my code:\r\n\r\n    function init () {\r\n        dropDownNav( $('.l-header-click-nav') );\r\n        dropDownNav( $('.m-sidebar-nav-dropdown') );\r\n        listing_action_btn($('.m-action-plus'));\r\n        toggle_show( $('.ajax-follow-toggle') );\r\n        toggle_watched( $('.ajax-watched-show-toggle') );\r\n        toggle_watched_episode( $('.ajax-watched-listing-toggle') );\r\n    }\r\n\r\n    $(function () {\r\n\r\n    init();\r\n\r\n    (function($tvshows_listing){\r\n\r\n        if($tvshows_listing.length)\r\n        {\r\n            /** Trigger Infinite Ajax Scroll **/\r\n            var ias = jQuery.ias({\r\n                container:  '#tvshows-listing',\r\n                item:       '.l-tvshows-listing-item',\r\n                pagination: '.m-pagination-tvshows',\r\n                next:       '.next-page-link'\r\n            });\r\n\r\n            ias.extension(new IASSpinnerExtension({\r\n                html: '<div class=\"ias-spinner m-listing-loading m-listing-tvshows-listing-loading\"><div class=\"bounce1\"></div><div class=\"bounce2\"></div><div class=\"bounce3\"></div></div>'\r\n            }));\r\n\r\n            ias.extension(new IASNoneLeftExtension({\r\n                text: 'There are no more...',\r\n                html: '<div class=\"ias-noneleft l-tvshows-listing-noneleft\">{text}<em class=\"f-tvrocks icon-frown-o\"></em></div>'\r\n            }));\r\n\r\n            ias.extension(new IASTriggerExtension({\r\n                offset: 5,\r\n                text: 'Load more',\r\n                textPrev: 'Load previous',\r\n                html: '<div class=\"ias-trigger ias-trigger-next m-listing-nav l-tvshows-listing-nav l-tvshows-listing-nav-next\"><a>{text} <em class=\"f-tvrocks icon-chevron-down\"></em></a></div>',\r\n                htmlPrev: '<div class=\"ias-trigger ias-trigger-prev m-listing-nav l-tvshows-listing-nav l-tvshows-listing-nav-prev\"><a><em class=\"f-tvrocks icon-chevron-up\"></em> {text}</a></div>'\r\n            }));\r\n\r\n            ias.extension(new IASPagingExtension());\r\n\r\n            ias.extension(new IASHistoryExtension({\r\n                prev: '.prev-page-link'\r\n            }));\r\n\r\n            ias.on('rendered', function() {\r\n                init();\r\n            });\r\n        }\r\n\r\n    })($('#tvshows-listing'));\r\n    });"},"comment":{"url":"https://api.github.com/repos/webcreate/infinite-ajax-scroll/issues/comments/123216885","html_url":"https://github.com/webcreate/infinite-ajax-scroll/issues/209#issuecomment-123216885","issue_url":"https://api.github.com/repos/webcreate/infinite-ajax-scroll/issues/209","id":123216885,"user":{"login":"fieg","id":1086908,"avatar_url":"https://avatars.githubusercontent.com/u/1086908?v=3","gravatar_id":"","url":"https://api.github.com/users/fieg","html_url":"https://github.com/fieg","followers_url":"https://api.github.com/users/fieg/followers","following_url":"https://api.github.com/users/fieg/following{/other_user}","gists_url":"https://api.github.com/users/fieg/gists{/gist_id}","starred_url":"https://api.github.com/users/fieg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fieg/subscriptions","organizations_url":"https://api.github.com/users/fieg/orgs","repos_url":"https://api.github.com/users/fieg/repos","events_url":"https://api.github.com/users/fieg/events{/privacy}","received_events_url":"https://api.github.com/users/fieg/received_events","type":"User","site_admin":false},"created_at":"2015-07-21T08:45:19Z","updated_at":"2015-07-21T08:45:19Z","body":"Glad to hear you worked in out! :+1: "}}