'', 'header_text'=>__('Call us : 984187523XX','bikashsoft'), 'show_search'=> true, 'welcome_post' => '', 'welcome_post_readmore' => __('Read More','bikashsoft'), 'welcome_post_char' => '650', 'show_fontawesome' => false, 'big_icons' => false, 'service_block1' => '', 'service_block2' => '', 'service_block3' => '', 'service_block_readmore' => __('Read More','bikashsoft'), 'service_block1_icon' => '', 'service_block2_icon' => '', 'service_block3_icon' => '', 'how_to_help_post' => '', 'how_to_help_post_readmore' => __('Read More','bikashsoft'), 'how_to_help_post_char' => '250', 'become_volunteer_post' => '', 'become_volunteer_post_readmore' => __('Sign Up Today','bikashsoft'), 'become_volunteer_post_char' => '650', 'donate_us_post' => '', 'donate_us_post_readmore' => __('Donate Now','bikashsoft'), 'donate_us_post_char' => '650', 'awareness_post' => '', 'awareness_post_readmore' => __('Donate Now','bikashsoft'), 'awareness_post_char' => '650', 'show_project_number' => '3', 'project_cat' => '', 'testimonial_cat' => '', 'portfolio_cat' => '', 'footer_copyright' => get_bloginfo('name'), 'show_slider' => 'yes', 'slider_show_pager' => 'yes1', 'slider_show_controls' => 'yes2', 'slider_mode' => 'slide', 'slider_auto' => 'yes3', 'slider_speed' => '500', 'slider_caption'=>'yes4', 'slider_pause' => '4000', 'slider1'=>'', 'slider2'=>'', 'slider3'=>'', 'slider4'=>'', 'leftsidebar_show_latest_projects'=>true, 'leftsidebar_show_testimonials'=>true, 'rightsidebar_show_latest_projects'=>true, 'rightsidebar_show_testimonials'=>true, 'bikashsoft_facebook' => '', 'bikashsoft_twitter' => '', 'bikashsoft_gplus' => '', 'bikashsoft_youtube' => '', 'bikashsoft_pinterest' => '', 'bikashsoft_linkedin' => '', 'bikashsoft_flickr' => '', 'bikashsoft_vimeo' => '', 'bikashsoft_stumbleupon' => '', 'bikashsoft_instagram' => '', 'bikashsoft_sound_cloud' => '', 'bikashsoft_skype' => '', 'bikashsoft_rss' => '', 'bikashsoft_tumblr' => '', 'bikashsoft_myspace' =>'', 'show_social_header'=>'', 'bikashsoft_home_page_layout' => 'Layout2', 'bikashsoft_webpage_layout' => 'Fullwidth', 'gallery_code' => '', 'slider_options' => 'single_post_slider', 'slider_cat' => '', 'view_all_text' =>__('View All','bikashsoft'), 'custom_css' => '', 'featured_bar' => false, 'welcome_post_content' => false, 'show_projectdate' => true, 'disable_project' => false, 'bikashsoft_home_template' => 'template_two', 'template_option_selected' =>'yes' ); add_action( 'admin_init', 'bikashsoft_register_settings' ); add_action( 'admin_menu', 'bikashsoft_theme_options' ); function bikashsoft_register_settings() { register_setting( 'bikashsoft_theme_options', 'bikashsoft_options', 'bikashsoft_validate_options' ); } function bikashsoft_theme_options() { // Add theme options page to the addmin menu add_theme_page( __( 'Theme Options', 'bikashsoft' ), __( 'Theme Options', 'bikashsoft' ), 'edit_theme_options', 'theme_options', 'bikashsoft_theme_options_page' ); } // Store Posts in array $bikashsoft_postlist[0] = array( 'value' => 0, 'label' => __('--choose--','bikashsoft') ); $arg = array('posts_per_page' => -1); $bikashsoft_posts = get_posts($arg); foreach( $bikashsoft_posts as $bikashsoft_post ) : $bikashsoft_postlist[$bikashsoft_post->ID] = array( 'value' => $bikashsoft_post->ID, 'label' => $bikashsoft_post->post_title ); endforeach; // Store Pages in array $bikashsoft_pagelist[0] = array( 'value' => 0, 'label' => __('--choose--','bikashsoft') ); $arg = array('posts_per_page' => -1); $bikashsoft_pages = get_pages($arg); foreach( $bikashsoft_pages as $bikashsoft_page ) : $bikashsoft_pagelist[$bikashsoft_page->ID] = array( 'value' => $bikashsoft_page->ID, 'label' => $bikashsoft_page->post_title ); endforeach; $bikashsoft_pagelist1 = array(); foreach( $bikashsoft_pages as $bikashsoft_page ) : $bikashsoft_pagelist1[$bikashsoft_page->ID] = array( 'value' => $bikashsoft_page->ID, 'label' => $bikashsoft_page->post_title ); endforeach; $bikashsoft_postpagelist = array_merge($bikashsoft_postlist, $bikashsoft_pagelist1); // Store categories in array $bikashsoft_catlist[0] = array( 'value' => 0, 'label' => __('--choose--','bikashsoft') ); $arg1 = array( 'hide_empty' => 0, 'orderby' => 'name', 'parent' => 0, ); $bikashsoft_cats = get_categories($arg1); foreach( $bikashsoft_cats as $bikashsoft_cat ) : $bikashsoft_catlist[$bikashsoft_cat->cat_ID] = array( 'value' => $bikashsoft_cat->cat_ID, 'label' => $bikashsoft_cat->cat_name ); endforeach; wp_reset_postdata(); // Store slider setting in array $bikashsoft_slider = array( 'yes' => array( 'value' => 'yes', 'label' => __('show','bikashsoft') ), 'no' => array( 'value' => 'no', 'label' => __('hide','bikashsoft') ), ); $bikashsoft_slider_show_pager = array( 'yes1' => array( 'value' => 'yes1', 'label' => __('yes','bikashsoft') ), 'no1' => array( 'value' => 'no1', 'label' => __('no','bikashsoft') ), ); $bikashsoft_slider_show_controls = array( 'yes2' => array( 'value' => 'yes2', 'label' => __('yes','bikashsoft') ), 'no2' => array( 'value' => 'no2', 'label' => __('no','bikashsoft') ), ); $bikashsoft_slider_auto = array( 'yes3' => array( 'value' => 'yes3', 'label' => __('yes','bikashsoft') ), 'no3' => array( 'value' => 'no3', 'label' => __('no','bikashsoft') ), ); $bikashsoft_slider_mode = array( 'fade' => array( 'value' => 'fade', 'label' => __('fade','bikashsoft') ), 'slide' => array( 'value' => 'slide', 'label' => __('slide','bikashsoft') ), ); $bikashsoft_slider_caption = array( 'yes4' => array( 'value' => 'yes4', 'label' => __('show','bikashsoft') ), 'no4' => array( 'value' => 'no4', 'label' => __('hide','bikashsoft') ), ); // Function to generate options page function bikashsoft_theme_options_page() { global $bikashsoft_options, $bikashsoft_postlist, $bikashsoft_postpagelist, $bikashsoft_slider, $bikashsoft_slider_show_pager, $bikashsoft_slider_show_controls, $bikashsoft_slider_mode, $bikashsoft_slider_auto, $bikashsoft_slider_caption, $bikashsoft_catlist; if ( ! isset( $_REQUEST['settings-updated'] ) ) $_REQUEST['settings-updated'] = false; // This checks whether the form has just been submitted. ?>