Iluvatar+ Posted November 23, 2012 Share Posted November 23, 2012 I have called some ajax to bring in some html. In their html there is a form with select box's which i have a replacement plugin. However, i have included my plugin and applied it in the main html document and wrapped in in the document ready function but it just won’t apply to new dom elements with the ajax call. Andy ideas? Quote Link to comment https://forums.phpfreaks.com/topic/271063-applying-a-function-to-new-ajax-elements/ Share on other sites More sharing options...
trq Posted November 23, 2012 Share Posted November 23, 2012 Look into event delegation. Google it. Quote Link to comment https://forums.phpfreaks.com/topic/271063-applying-a-function-to-new-ajax-elements/#findComment-1394576 Share on other sites More sharing options...
Iluvatar+ Posted November 23, 2012 Author Share Posted November 23, 2012 I have sorted the problem now just applied it in the ajax function. Thanks for you reply. Quote Link to comment https://forums.phpfreaks.com/topic/271063-applying-a-function-to-new-ajax-elements/#findComment-1394585 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.