How to prevent jQuery from loading during ajax callback Using Drupal 7's implementation of jQuery and Drupal.behaviors, how can I get some of my jQuery to run only once when the page is initially loaded, and the rest to run when the page is loaded AND during AJAX callbacks.

How can I prevent ajax callbacks from triggering certain parts of my Drupal.behaviors?

(function ($) {
    Drupal.behaviors.fsrevs_user = {
        attach: function (context, settings) {

            //I want to run this only during the first page load.
            jQuery('#edit-message').after('&lt;div&gt;Do Once&lt;/div&gt;');

            //I want this to run during first load and during each ajax callback.
            jQuery('#edit-message').after('&lt;div&gt;Do Every Time&lt;/div&gt;');
        }
    }

})(jQuery);
This'll do it:

var msg = $('#edit-message');
msg.once('fsrevs_user', function() {
  msg.after('&lt;div&gt;Do Once&lt;/div&gt;');
});

msg.after('&lt;div&gt;Do Every Time&lt;/div&gt;');