Skip to content

Instantly share code, notes, and snippets.

@MattWilliamsDev
Created November 20, 2014 20:56
Show Gist options
  • Select an option

  • Save MattWilliamsDev/96adc9fe9e0753431c56 to your computer and use it in GitHub Desktop.

Select an option

Save MattWilliamsDev/96adc9fe9e0753431c56 to your computer and use it in GitHub Desktop.
$( '.smart-form input, .smart-form input[disabled], .smart-form textarea, .smart-form select' ).each( function() {
var name = $( this ).attr( 'name' );
if ( jsonData && jsonData[ name ] ) {
$( this ).val( jsonData[ name ] );
}
} );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment