any ideas?
On 10 Feb., 17:31, dirk w <dirkwendl...@googlemail.com> wrote: > hello, > i am getting a script which calls back some json to my function > "showMyVideos". > during my research in this group i read that getScript wouldn't cache. > in my case i would like to add some cache (lazy loading) to my > getScript function since it isn't necessary to update a already > searched result (during one session). > > i am not an expert on jquery.ajax and didn't figured it out. i guess i > messed it up with the "execution" of the link (remember: there's a > callback function to call). > > ##### works, but doesn't cache > $("#searchForm").submit(function() > { > $val = $('#searchText').val(); > $url = 'http://gdata.youtube.com/feeds/api/videos?q='+ $val + > '&alt=json-in-script&callback=showMyVideos&max-results=50&format=5'; > $.getScript($url); > > });