Skip to content

Instantly share code, notes, and snippets.

@wsmoak
Last active April 1, 2016 02:46
Show Gist options
  • Save wsmoak/25abd88e65b72cd5f04ec525b7482f64 to your computer and use it in GitHub Desktop.
Save wsmoak/25abd88e65b72cd5f04ec525b7482f64 to your computer and use it in GitHub Desktop.
$(document).ready(function(){
$.getScript( "https://d79i1fxsrar4t.cloudfront.net/jquery.liveaddress/2.8/jquery.liveaddress.min.js" )
.done(function( script, textStatus ) {
console.log( "liveaddress loaded " + textStatus );
var liveaddress = $.LiveAddress({
key: "01234567890",
debug: true,
autocomplete: 5,
autoVerify: false,
addresses:[{
street: '#subscription_payment_profile_attributes_billing_address',
city: '#subscription_payment_profile_attributes_billing_city',
state: '#subscription_payment_profile_attributes_billing_state',
zipcode: '#subscription_payment_profile_attributes_billing_zip'
}]
}); //end liveaddress configure
console.log( "liveaddress configured " );
}) //end done
.fail(function( jqxhr, settings, exception ) {
console.log( "failed to load liveaddress" );
}); //end fail
}); //end document ready
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment