SchweppesAle Posted January 22, 2010 Share Posted January 22, 2010 the following function won't work for some reason. I'd like to place the html returned from an ajax request within a div element. function showPopup(id) { //make the ajax call var req = new Request({ method: 'get', url: 'some php file', data: { 'do' : '1' }, /* onRequest: function() { alert('Request made. Please wait...'); },*/ onComplete: function(response) { /* $('product').set('html',response);*//* document.getElementById('popUP').innerHTML = response;*/ $.('popUP').set('html', response); } }).send(); } alert returns the html, so I know receiving a response from the script isn't an issue. any ideas? Quote Link to comment Share on other sites More sharing options...
RichardRotterdam Posted January 22, 2010 Share Posted January 22, 2010 Only thing wrong I can see is that you're using a dot after the dollar character change: $.('popUP').set('html', response); to: $('popUP').set('html', response); Quote Link to comment Share on other sites More sharing options...
SchweppesAle Posted January 22, 2010 Author Share Posted January 22, 2010 Only thing wrong I can see is that you're using a dot after the dollar character change: $.('popUP').set('html', response); to: $('popUP').set('html', response); *slams head on keyboard* Quote Link to comment 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.