Skip to content

Instantly share code, notes, and snippets.

@plugin-republic
Created November 7, 2019 10:02
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 plugin-republic/ce0677188fe82b6828a881ba69609bc8 to your computer and use it in GitHub Desktop.
Save plugin-republic/ce0677188fe82b6828a881ba69609bc8 to your computer and use it in GitHub Desktop.
<?php
/**
* Add new options to the global Product Add-Ons Ultimate settings
*/
function prefix_filter_settings( $settings ) {
$settings['prefix_section_title'] = array(
'name' => __( 'New Title', 'pewc' ),
'type' => 'title',
'desc' => '',
'id' => 'prefix_section_title'
);
$settings['prefix_upper_value'] = array(
'name' => __( 'Upper value', 'pewc' ),
'type' => 'number',
'id' => 'prefix_upper_value',
'default' => '180',
'std' => '180'
);
$settings['prefix_lower_value'] = array(
'name' => __( 'Lower value', 'pewc' ),
'type' => 'number',
'id' => 'prefix_lower_value',
'default' => '155',
'std' => '155'
);
$settings['prefix_section_end'] = array(
'type' => 'sectionend',
'id' => 'prefix_section_title'
);
return $settings;
}
add_filter( 'pewc_filter_settings', 'prefix_filter_settings' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment