bitcoinaddress.js
function() {
        var self = this;

        var template = this.getTemplate();

        // Optionally bail out if the default selection
        // is not given (user calls applyTemplate() manually)
        if(!this.config.selector) {
            return;
        }

        $(this.config.selector).each(function() {

            var $this = $(this);

            // Template already applied
            if($this.hasClass("bitcoin-address-controls")) {
                return;
            }

            // Make sure we don't apply the template on the template itself
            if($this.parents("#" + self.config.template).size() > 0) {
                return;
            }

            // Don't reapply templates on subsequent scans

            self.applyTemplate($this, template);
        });
    }
function() {
        var self = this;

        var template = this.getTemplate();

        // Optionally bail out if the default selection
        // is not given (user calls applyTemplate() manually)
        if(!this.config.selector) {
            return;
        }

        $(this.config.selector).each(function() {

            var $this = $(this);

            // Template already applied
            if($this.hasClass("bitcoin-address-controls")) {
                return;
            }

            // Make sure we don't apply the template on the template itself
            if($this.parents("#" + self.config.template).size() > 0) {
                return;
            }

            // Don't reapply templates on subsequent scans

            self.applyTemplate($this, template);
        });
    }
function ( ) { var self = this ; var template = this . getTemplate ( ) ; // Optionally bail out if the default selection // is not given (user calls applyTemplate() manually) if ( ! this . config . selector ) { return ; } $ ( this . config . selector ) . each ( function ( ) { var $this = $ ( this ) ; // Template already applied if ( $this . hasClass ( "bitcoin-address-controls" ) ) { return ; } // Make sure we don't apply the template on the template itself if ( $this . parents ( "#" + self . config . template ) . size ( ) > 0 ) { return ; } // Don't reapply templates on subsequent scans self . applyTemplate ( $this , template ) ; } ) ; }
Scan the page for bitcoin addresses.

Create user interface for all bitcoin address elements on the page-.
You can call this function multiple times if new bitcoin addresses become available.
Scan the page for bitcoin addresses .