Shrabanee Report post Posted December 6, 2017 Hi, I am trying to use 'link' but unable to make it work when function is not defined in the <script> tag in html. Please refer https://jsfiddle.net/em5Lv48r/3/ Clicking on Foods will show alert but clicking on Apparels will give error in console as 'hello1 is not defined'. Why link functionality is not working with 'hello1' function which is defined in the js part? Share this post Link to post Share on other sites
Ayan Bhadury Report post Posted December 7, 2017 Hi, You need to make the function available to the window document in order to execute it. Please check the sample fiddle - https://jsfiddle.net/nvs76f62/ Share this post Link to post Share on other sites