set_parent_slug($parent_slug); $option_theme_license->add_field(array('id' => 'customer_email', 'title' => __('Customer email', 'fansub'))); $option_theme_license->add_field(array('id' => 'license_code', 'title' => __('License code', 'fansub'))); $option_theme_license->add_help_tab(array( 'id' => 'overview', 'title' => __('Overview', 'fansub'), 'content' => '

' . sprintf(__('Thank you for using WordPress theme by %s.', 'fansub'), FANSUB_NAME) . '

' . '

' . __('With each theme, you will receive a license code to activate it. Please enter your theme license information into the form below, if you do not have one, please contact the author to get new code.', 'fansub') . '

' )); $option_theme_license->set_help_sidebar( '

' . __('For more information:', 'fansub') . '

' . '

' . __('Rules of using license', 'fansub') . '

' . '

' . __('Contact Us', 'fansub') . '

' ); $option_theme_license->init(); fansub_option_add_object_to_list($option_theme_license); function fansub_theme_license_option_saved($option) { if(is_a($option, 'FANSUB_Option')) { fansub_delete_transient_license_valid(); } } add_action($option_theme_license->get_menu_slug() . '_option_saved', 'fansub_theme_license_option_saved');