small medium large xlarge

07 Feb 2011, 09:33
F.J. Kraan (1 post)

The code for the Viewport example (p.45) displays the link to previous comments visible even after those comments are inserted. This allows the user to insert multiple sets of those comments. The addition of a ‘onComplete’ function to the new Ajax.Request call seems to solve this problem.

    var upd = new Ajax.Request('known_comments.html', {
      method: 'get',
      onComplete: function() { $('extraComments').hide(); },
      onSuccess: function(res) {