Skip to content

Instantly share code, notes, and snippets.

@tripflex
Created April 22, 2019 18:41
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 tripflex/d7439ac157b83ae151d31620bfd5f8cb to your computer and use it in GitHub Desktop.
Save tripflex/d7439ac157b83ae151d31620bfd5f8cb to your computer and use it in GitHub Desktop.
Customize label when using Auto Output with WP Job Manager Field Editor
<?php
add_filter( 'field_editor_output_as_args', 'smyles_my_custom_label_output', 10, 4 );
function smyles_my_custom_label_output( $args, $field_value, $meta_key, $listing_id ){
if( $meta_key === 'my_meta_key' ){
$args['label'] = "My Custom Label";
}
return $args;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment