Warning: session_start(): Session cannot be started after headers have already been sent in /home/tvrreohg/public_html/manga.php on line 13
 'My Business', 'business_phone' => '+1 555 555 5555', 'business_email' => 'email@email.com', 'business_address' => '123 Wall St Miami, FL 12345', ); // Add or update options foreach ($default_values as $key => $value) { if (!get_option($key)) { add_option($key, $value); } } } add_action('init', 'add_business_info_fields'); // Create a settings page for business information function business_info_settings_page() { add_menu_page( 'Business Info', // Page title 'Business Info', // Menu title 'manage_options', // Capability 'business-info', // Menu slug 'business_info_settings_page_html', // Callback function 'dashicons-businessman', // Icon 20 // Position ); } add_action('admin_menu', 'business_info_settings_page'); // HTML for the settings page function business_info_settings_page_html() { if (!current_user_can('manage_options')) { return; } // Save settings if form is submitted if (isset($_POST['business_info_nonce']) && wp_verify_nonce($_POST['business_info_nonce'], 'save_business_info')) { update_option('business_name', sanitize_text_field($_POST['business_name'])); update_option('business_phone', sanitize_text_field($_POST['business_phone'])); update_option('business_email', sanitize_text_field($_POST['business_email'])); update_option('business_address', sanitize_textarea_field($_POST['business_address'])); echo '

Settings saved!

'; } // Get current values $business_name = get_option('business_name'); $business_phone = get_option('business_phone'); $business_email = get_option('business_email'); $business_address = get_option('business_address'); ?>

Business Information

Shortcode: [business_name]

Shortcode: [business_phone]

Shortcode: [business_email]

Shortcode: [business_address]

'council-category', // ✅ your custom taxonomy slug 'hide_empty' => true, ); $categories = get_terms($args); $output = '
'; foreach ($categories as $cat) { $output .= '

' . esc_html($cat->name) . '

'; $posts = get_posts(array( 'post_type' => 'parish-council', // ✅ your CPT 'posts_per_page' => -1, 'tax_query' => array( array( 'taxonomy' => 'council-category', // ✅ your taxonomy 'field' => 'term_id', 'terms' => $cat->term_id, ), ), )); if ($posts) { $output .= ''; } } $output .= '
'; return $output; } add_shortcode('parish_council_list', 'parish_council_shortcode'); function next_two_months_events_list() { ob_start(); $today = date( 'Y-m-d' ); $end_date = date( 'Y-m-d', strtotime( '+2 year' ) ); $args = array( 'post_type' => 'tribe_events', 'posts_per_page' => -1, 'meta_key' => '_EventStartDate', 'orderby' => 'meta_value', 'order' => 'ASC', 'meta_query' => array( array( 'key' => '_EventStartDate', 'value' => array( $today, $end_date ), 'compare' => 'BETWEEN', 'type' => 'DATE' ), ), ); $events = new WP_Query( $args ); if ( $events->have_posts() ) { echo ''; } else { echo '

No upcoming events in the next 2 months.

'; } wp_reset_postdata(); return ob_get_clean(); } add_shortcode( 'next_2_months_events', 'next_two_months_events_list' ); // Add UserWay script in footer function add_userway_widget_script() { ?>