Skip to content

Instantly share code, notes, and snippets.

@spivurno
Created March 26, 2019 12:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save spivurno/d3ddce62882808d6dae177c3a528e2f1 to your computer and use it in GitHub Desktop.
Save spivurno/d3ddce62882808d6dae177c3a528e2f1 to your computer and use it in GitHub Desktop.
<script type="text/javascript">
gform.addFilter( 'gppc_copied_value', function( value, $elem, data ) {
// Update "1" to the ID of the field being copied to.
if( data.target == 1 && value ) {
value = value.split( '|' )[0];
}
return value;
} );
</script>
@spivurno
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment