I have 2 html files
1. main.html 2. external.html - contains script tag
external content will be loaded to main.html once a user click the button using jquery.load function
Now my problem is if the user click twice the load button, the functions inside the external.html fires twice also even if i emptied the div element in main.html
i tried
empty()and
html("")functions to clear out the content of the div but still no luck.
this is my code http://plnkr.co/edit/XLZGquoebTTHahgJWNOk?p=preview