<?php /** * FoodTechPro functions and definitions */ if ( ! defined( 'ABSPATH' ) ) exit; define( 'FOODTECHPRO_VERSION', '1.0.0' ); // --------------------------------------------------------------- // Theme setup // --------------------------------------------------------------- function foodtechpro_setup() { load_theme_textdomain( 'foodtechpro', get_template_directory() . '/languages' ); add_theme_support( 'automatic-feed-links' ); add_theme_support( 'title-tag' ); add_theme_support( 'post-thumbnails' ); add_theme_support( 'html5', [ 'search-form', 'comment-form', 'comment-list', 'gallery', 'caption', 'style', 'script' ] ); add_theme_support( 'customize-selective-refresh-widgets' ); add_theme_support( 'wp-block-styles' ); add_theme_support( 'align-wide' ); add_image_size( 'foodtechpro-hero', 1280, 720, true ); add_image_size( 'foodtechpro-card', 800, 533, true ); add_image_size( 'foodtechpro-thumb', 400, 267, true ); register_nav_menus( [ 'primary' => __( 'Primary Menu', 'foodtechpro' ), 'footer' => __( 'Footer Menu', 'foodtechpro' ), ] ); } add_action( 'after_setup_theme', 'foodtechpro_setup' ); // --------------------------------------------------------------- // Enqueue scripts & styles // --------------------------------------------------------------- function foodtechpro_scripts() { // Main stylesheet wp_enqueue_style( 'foodtechpro-style', get_stylesheet_uri(), [], FOODTECHPRO_VERSION ); // Enhanced responsive stylesheet wp_enqueue_style( 'foodtechpro-responsive', get_template_directory_uri() . '/responsive.css', [ 'foodtechpro-style' ], FOODTECHPRO_VERSION ); // Responsive navigation & interactions (includes mobile menu, search toggle, keyboard a11y) // Note: navigation.js kept as reference; responsive.js is the active handler wp_enqueue_script( 'foodtechpro-responsive', get_template_directory_uri() . '/js/responsive.js', [], FOODTECHPRO_VERSION, true ); if ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) { wp_enqueue_script( 'comment-reply' ); } } add_action( 'wp_enqueue_scripts', 'foodtechpro_scripts' ); // --------------------------------------------------------------- // Widget areas // --------------------------------------------------------------- function foodtechpro_widgets_init() { register_sidebar( [ 'name' => __( 'Blog Sidebar', 'foodtechpro' ), 'id' => 'sidebar-1', 'description' => __( 'Add widgets here to appear in the blog sidebar.', 'foodtechpro' ), 'before_widget' => '<section id="%1$s" class="widget %2$s">', 'after_widget' => '</section>', 'before_title' => '<h3 class="widget-title">', 'after_title' => '</h3>', ] ); register_sidebar( [ 'name' => __( 'Footer Column 1', 'foodtechpro' ), 'id' => 'footer-1', 'before_widget' => '<section id="%1$s" class="widget %2$s">', 'after_widget' => '</section>', 'before_title' => '<h3 class="widget-title">', 'after_title' => '</h3>', ] ); } add_action( 'widgets_init', 'foodtechpro_widgets_init' ); // --------------------------------------------------------------- // Excerpt length // --------------------------------------------------------------- function foodtechpro_excerpt_length( $length ) { return 25; } add_filter( 'excerpt_length', 'foodtechpro_excerpt_length' ); function foodtechpro_excerpt_more( $more ) { return '&hellip; <a class="read-more" href="' . get_permalink() . '">' . __( 'Read more', 'foodtechpro' ) . '</a>'; } add_filter( 'excerpt_more', 'foodtechpro_excerpt_more' ); // --------------------------------------------------------------- // Body classes // --------------------------------------------------------------- function foodtechpro_body_classes( $classes ) { if ( is_singular() ) $classes[] = 'singular'; if ( ! is_singular() ) $classes[] = 'hfeed'; return $classes; } add_filter( 'body_class', 'foodtechpro_body_classes' ); // --------------------------------------------------------------- // Category icon helper // --------------------------------------------------------------- function foodtechpro_category_icon( $slug ) { $icons = [ 'food-industry' => '🏭', 'food-safety' => '🛡️', 'food-technology' => '🔬', 'fssai-updates' => '📋', 'research' => '📊', ]; echo esc_html( $icons[ $slug ] ?? '📝' ); } // --------------------------------------------------------------- // Custom logo defaults // --------------------------------------------------------------- function foodtechpro_custom_logo_setup() { add_theme_support( 'custom-logo', [ 'height' => 60, 'width' => 200, 'flex-width' => true, 'flex-height' => true, ] ); } add_action( 'after_setup_theme', 'foodtechpro_custom_logo_setup' );
Skip to content

Latest Articles

Market Intelligence

Data-Driven Decision Making in the Food Industry: A Complete Guide

 Decision Making in the Food Industry with Data In today\’s fast-paced and highly competitive world, making data-driven decisions has become essential for businesses across industries, and the food industry is no exception. With increasing consumer demands, changing trends, and intense competition, companies in the food industry are relying on data to gain insights and make […]

FoodTechPro Team
Nutrition & Health

Meal Replacement Shakes: The Ultimate Guide to Nutrition and Choices

 Meal Replacement Shakes: The Ultimate Guide If you\’re looking for a convenient and effective way to lose weight, gain weight, or simply maintain a healthy lifestyle, meal replacement shakes may be the answer. These shakes are designed to provide all the nutrients your body needs in a convenient and easy-to-consume form. In this article, we\’ll […]

FoodTechPro Team
Nutrition & Health

CBD Oil : Cancer Treatment, Its Medicinal Properties Can Benefit Your Health.

  CBD Oil : Cancer Treatment, Its Medicinal Properties Can Benefit Your Health. CBD oil has been making headlines for its potential medicinal properties. CBD, or cannabidiol, is a natural compound found in cannabis plants that does not produce the psychoactive effects commonly associated with marijuana use. Here\’s a closer look at how oil medicinal […]

FoodTechPro Team
Food Processing & Manufacturing

Sustainable Food Packaging: A Step Towards a Greener Future.

Sustainable Food Packaging: A Step Towards a Greener Future Introduction: In recent years, the world has seen a growing concern about the impact of human activities on the environment. One of the biggest challenges we face today is the issue of waste management, particularly in the food industry. Every year, billions of tons of plastic […]

FoodTechPro Team
Food Processing & Manufacturing

Cost-Effective Methods for Fortified Flour Production

 Cost-Effective Methods for Fortified Flour Production Introduction Fortified flour is a crucial food product that addresses nutritional deficiencies, particularly in regions where access to diverse diets is limited. It is fortified with essential vitamins and minerals, such as iron, folic acid, and vitamins A, B, and D, to improve public health and combat malnutrition. However, […]

FoodTechPro Team
Nutrition & Health

Date Seed Coffee: A Caffeine-Free Delight for Your Palate

  Date Seed Coffee: A Caffeine-Free Delight for Your Palate In the fast-paced world we live in, caffeine often plays a central role in keeping us alert and awake. However, for those looking to reduce their caffeine intake or eliminate it altogether, Date Seed Coffee is a delightful alternative that promises the same comforting warmth […]

FoodTechPro Team
Market Intelligence

Food Security in India: Challenges, Policies, and Future Outlook

  Food Security In India Food security is a critical issue in India, with millions of people still struggling to access affordable and nutritious food. Despite being one of the largest food producers in the world, India faces significant challenges in ensuring food security for its vast and diverse population. In this article, we will examine […]

FoodTechPro Team
Food Processing & Manufacturing

Food Processing Industry Trends and Predictions for the New Year

Food Processing Industry Trends and Predictions for the New Year Introduction The food processing industry is constantly evolving, driven by changing consumer preferences, technological breakthroughs, and global supply chain dynamics. According to Grand View Research, the global food processing market was valued at $165.6 billion in 2023 and is expected to grow at a CAGR […]

FoodTechPro Team
Food Safety

Important Things for Freshers to Know in the Food Industry

Important Things for Freshers to Know in the Food Industry Introduction: When you start working in the food industry, especially in the fields of quality production, R&D, and regulatory affairs, it\’s important to have a lot of knowledge. Here are some important things that freshers should know, including information about FSSAI guidelines: Prashant Chavhan March 06, […]

FoodTechPro Team
Nutrition & Health

Diet Chart For Polycystic Ovarian Disease (PCOD)

  Diet Chart For Polycystic Ovarian Disease (PCOD) Diet for PCOD & its Importance: Polycystic ovarian disease (PCOD) is a hormonal disorder that affects women of reproductive age. Women with PCOD have enlarged ovaries that contain small fluid-filled sacs or cysts. This disorder can cause hormonal imbalance, irregular periods, weight gain and fertility problems. Diet plays a crucial […]

FoodTechPro Team