' . $msg . '

'; } public function acpf_un_set_cat_post_options() { delete_option('add_cat_post_footer_opts'); } public function acpf_set_cat_post_options() { add_option('add_cat_post_footer_opts',''); $this->default_set_dat(); } public function default_set_dat(){ $options['default'] = array( "acpf_optional_txt" => 'this is default footer data', ); update_option("add_cat_post_footer_opts", $options); } public function acpf_options_page() { if(isset($_REQUEST['insert'])) { $this->add_new_footer(); } elseif(isset($_REQUEST['update']) ) { $up_cat=$_REQUEST['update']; $this->update_cat_name($up_cat); } elseif(isset($_REQUEST['del']) ) { $del_cat_nam=$_REQUEST['del']; $all_cat_nam=get_option("add_cat_post_footer_opts"); unset($all_cat_nam[$del_cat_nam]); update_option("add_cat_post_footer_opts", $all_cat_nam); $del_my_location= admin_url().'options-general.php?page=add-categories-post-footer/add_categories_post_footer.php'; ?>

Add-Categories-Post-Footer : Add New

$desc_info) { ?>
Categories Name Post Footer Description delete update
delete Update
$desc_info) { $options[$cat_old_nam] = array( "acpf_optional_txt" => $desc_info['acpf_optional_txt'], ); } $cat_nam=$_POST["cat_nam"]; $options[$cat_nam] = array( "acpf_optional_txt" => $_POST["acpf_optional_txt"], ); update_option("add_cat_post_footer_opts", $options); $this->apf_show_info_msg("Add-Categories-Post-Footer options saved."); $add_my_location= admin_url().'options-general.php?page=add-categories-post-footer/add_categories_post_footer.php'; ?>

10, 'teeny' => false, 'textarea_name'=>'acpf_optional_txt', 'quicktags' => true, 'media_buttons' => true, // 'wpautop' => true, // 'tabindex' => '', // 'tabfocus_elements' => ':prev,:next', // 'editor_css' => '', // 'editor_class' => '', // 'dfw' => false, // 'tinymce' => false, ); wp_editor( ' ', 'editor1', $args ); ?>

apf_show_info_msg("Add-Categories-Post-Footer options saved."); $up_my_location= admin_url().'options-general.php?page=add-categories-post-footer/add_categories_post_footer.php'; ?>

10, 'teeny' => false, 'textarea_name'=>'up_acpf_optional_txt', 'quicktags' => true, 'media_buttons' => true, // 'wpautop' => true, // 'tabindex' => '', // 'tabfocus_elements' => ':prev,:next', // 'editor_css' => '', // 'editor_class' => '', // 'dfw' => false, // 'tinymce' => false, ); wp_editor( $old_cat_nam2, 'editor1', $args ); ?>


'; // global $post; $post_categories = wp_get_post_categories( $post->ID ); $cont=0; foreach($post_categories as $c){ $cat = get_category( $c ); $cat_name = $cat->name; $cont++; //$text .= $cats[] = array( 'name' => $cat->name, 'slug' => $cat->slug ); } if($cont==1){ $cat_name; $display_cat_desc=get_option("add_cat_post_footer_opts"); $txt=$display_cat_desc[$cat_name]['acpf_optional_txt']; $text1=stripslashes($txt); $text2=stripslashes($text1); $text.=stripslashes($text2); } if($cont>=2){ $display_cat_desc=get_option("add_cat_post_footer_opts"); $text .=$display_cat_desc['default']['acpf_optional_txt']; } return $text; } } $add_categories_post_footer = new addnewcategoriespostfooter(); ?>