Skip to content

Professional Equipment + Education

Menu

Perform Better Pro-Ed

Move Train Perform

Professional equipment, movement systems and education for people who take movement seriously.

CHUNK 4 OF 4 — lines 2112–2675 ``` + return array( + 'key' => 'field_pbpe_home_tab_' . $name, + 'label' => $label, + 'name' => '', + 'type' => 'tab', + 'placement' => 'top', + 'endpoint' => 0, + ); +} - $args = array( - 'status' => 'publish', - 'limit' => -1, - 'paginate' => false, - 'visibility' => 'visible', - 'orderby' => 'menu_order', - 'order' => 'ASC', - 'return' => 'objects', +/** + * ACF image field owned by the static Front Page. + * + * @return array + */ +function pbpe_home_acf_image_field(string $name, string $label, string $instructions): array { + return array( + 'key' => 'field_' . $name, + 'label' => $label, + 'name' => $name, + 'type' => 'image', + 'instructions' => $instructions, + 'required' => 0, + 'return_format' => 'id', + 'library' => 'all', + 'preview_size' => 'medium', + 'mime_types' => 'jpg,jpeg,png,webp,avif', ); +} + +/** + * Register replaceable Homepage editorial photography when ACF is active. + */ +function pbpe_home_register_acf_fields(): void { + if (! function_exists('acf_add_local_field_group')) { + return; + } - if (taxonomy_exists('pa_education-type')) { - $args['tax_query'] = array( - array( - 'taxonomy' => 'pa_education-type', - 'operator' => 'NOT EXISTS', + acf_add_local_field_group( + array( + 'key' => 'group_pbpe_homepage_imagery', + 'title' => __('Homepage imagery', 'perform-better-pro-ed'), + 'fields' => array( + pbpe_home_acf_tab('hero', __('Hero', 'perform-better-pro-ed')), + pbpe_home_acf_image_field( + 'pbpe_home_hero_image', + __('Hero image', 'perform-better-pro-ed'), + __('Recommended source: at least 1536 × 1024px landscape. Keep the subject clear at the approved 70% horizontal focal point; the theme applies separate mobile and desktop vertical crops.', 'perform-better-pro-ed') + ), + pbpe_home_acf_tab('more', __('More Than Equipment', 'perform-better-pro-ed')), + pbpe_home_acf_image_field( + 'pbpe_home_more_equipment_image', + __('Equipment image', 'perform-better-pro-ed'), + __('Recommended source: approximately 1672 × 941px landscape. The theme applies the approved centred crop.', 'perform-better-pro-ed') + ), + pbpe_home_acf_image_field( + 'pbpe_home_more_systems_image', + __('Systems image', 'perform-better-pro-ed'), + __('Recommended source: approximately 1672 × 941px landscape. Allow room around the subject for the approved responsive crop.', 'perform-better-pro-ed') + ), + pbpe_home_acf_image_field( + 'pbpe_home_more_education_image', + __('Education image', 'perform-better-pro-ed'), + __('Recommended source: approximately 1672 × 941px landscape. Allow room around the subject for the approved responsive crop.', 'perform-better-pro-ed') + ), + pbpe_home_acf_tab('applications', __('Explore By Application', 'perform-better-pro-ed')), + pbpe_home_acf_image_field( + 'pbpe_home_application_strength_image', + __('Strength & Power image', 'perform-better-pro-ed'), + __('Recommended source: at least 1448 × 1086px. The theme presents this as the lead landscape feature.', 'perform-better-pro-ed') + ), + pbpe_home_acf_image_field( + 'pbpe_home_application_mobility_image', + __('Mobility & Movement image', 'perform-better-pro-ed'), + __('Recommended source: at least 1240 × 1268px with room for the approved portrait desktop crop and compact mobile row.', 'perform-better-pro-ed') + ), + pbpe_home_acf_image_field( + 'pbpe_home_application_functional_image', + __('Functional Training image', 'perform-better-pro-ed'), + __('Recommended source: at least 1736 × 1698px. Keep the important detail low in frame for the approved crop.', 'perform-better-pro-ed') + ), + pbpe_home_acf_image_field( + 'pbpe_home_application_speed_image', + __('Speed & Agility image', 'perform-better-pro-ed'), + __('Recommended source: at least 1790 × 1782px with the action near the centre of frame.', 'perform-better-pro-ed') + ), + pbpe_home_acf_image_field( + 'pbpe_home_application_recovery_image', + __('Recovery image', 'perform-better-pro-ed'), + __('Recommended source: at least 1490 × 1055px with room for the approved responsive crop.', 'perform-better-pro-ed') + ), + pbpe_home_acf_tab('systems', __('Training Systems', 'perform-better-pro-ed')), + pbpe_home_acf_image_field( + 'pbpe_home_system_vipr_image', + __('Featured ViPR PRO image', 'perform-better-pro-ed'), + __('Recommended source: at least 1536 × 1024px. Keep the athlete and coach visible across the approved mobile and desktop focal positions.', 'perform-better-pro-ed') + ), + pbpe_home_acf_tab('education', __('Professional Education', 'perform-better-pro-ed')), + pbpe_home_acf_image_field( + 'pbpe_home_education_image', + __('Professional Education image', 'perform-better-pro-ed'), + __('Recommended source: at least 1145 × 1374px portrait. The theme uses a wide mobile crop and a tall desktop composition.', 'perform-better-pro-ed') + ), + pbpe_home_acf_tab('insights', __('Insights', 'perform-better-pro-ed')), + pbpe_home_acf_image_field( + 'pbpe_home_insight_movement_image', + __('Movement & Training image', 'perform-better-pro-ed'), + __('Recommended source: at least 1536 × 1024px landscape. The theme applies the approved movement crop.', 'perform-better-pro-ed') + ), + pbpe_home_acf_image_field( + 'pbpe_home_insight_coaching_image', + __('Coaching & Practice image', 'perform-better-pro-ed'), + __('Recommended source: at least 1536 × 1024px landscape. Keep the subjects high enough for the approved focal position.', 'perform-better-pro-ed') + ), + pbpe_home_acf_image_field( + 'pbpe_home_insight_learning_image', + __('Professional Learning image', 'perform-better-pro-ed'), + __('Recommended source: at least 1536 × 1024px landscape. The theme applies the approved centred crop.', 'perform-better-pro-ed') + ), + pbpe_home_acf_tab('support', __('Professional Support', 'perform-better-pro-ed')), + pbpe_home_acf_image_field( + 'pbpe_home_support_image', + __('Professional Support image', 'perform-better-pro-ed'), + __('Recommended source: at least 1668 × 943px landscape. Keep both people visible across the approved mobile and desktop crops.', 'perform-better-pro-ed') + ), ), - ); + 'location' => array( + array( + array( + 'param' => 'page_type', + 'operator' => '==', + 'value' => 'front_page', + ), + ), + ), + 'position' => 'normal', + 'style' => 'default', + 'active' => true, + 'show_in_rest' => 0, + ) + ); +} +add_action('acf/init', 'pbpe_home_register_acf_fields'); + +/** + * Page currently assigned as the static Front Page. + */ +function pbpe_home_front_page_id(): int { + if ('page' !== get_option('show_on_front')) { + return 0; } - $products = wc_get_products($args); + $page_id = (int) get_option('page_on_front'); + + return $page_id > 0 ? $page_id : 0; +} - if (! is_array($products)) { - return array(); +/** + * Valid image attachment selected for one Homepage image field. + */ +function pbpe_home_image_id(string $field_name): int { + $page_id = pbpe_home_front_page_id(); + + if ($page_id 0 && wp_attachment_is_image($attachment_id) ? $attachment_id : 0; } /** - * Published visible Education products. + * Responsive attachment markup for an administrator-selected Homepage image. * - * @return array + * @param array $attributes Image attributes. */ -function pbpe_home_education(): array { - if (! function_exists('wc_get_products') || ! taxonomy_exists('pa_education-type')) { - return array(); +function pbpe_home_image(string $field_name, string $fallback_alt, array $attributes = array()): string { + $attachment_id = pbpe_home_image_id($field_name); + + if ($attachment_id 'publish', - 'limit' => -1, - 'paginate' => false, - 'visibility' => 'visible', - 'orderby' => 'menu_order', - 'order' => 'ASC', - 'return' => 'objects', - 'tax_query' => array( - array( - 'taxonomy' => 'pa_education-type', - 'operator' => 'EXISTS', - ), - ), - ) + 'alt' => '' !== $stored_alt ? $stored_alt : $fallback_alt, + 'decoding' => 'async', + ), + $attributes ); + $image = wp_get_attachment_image($attachment_id, 'full', false, $attributes); - if (! is_array($products)) { - return array(); + return is_string($image) ? $image : ''; +} + +/** + * Permalink of a published page assigned to a theme template. + */ +function pbpe_home_template_url(string $template): string { + if (function_exists('pbpe_education_template_url')) { + return pbpe_education_template_url($template); } - $education = array(); + return ''; +} - foreach ($products as $product) { - if ($product instanceof WC_Product) { - $education[] = $product; +/** + * Dynamic destinations used by the approved Homepage presentation. + * + * @return array + */ +function pbpe_home_destinations(): array { + $structural = function_exists('pbpe_structural_urls') ? pbpe_structural_urls() : array(); + $systems = pbpe_home_template_url('page-templates/systems-landing.php'); + $education = function_exists('pbpe_education_catalogue_url') ? pbpe_education_catalogue_url() : ''; + $brands = pbpe_home_template_url('page-templates/brands-directory.php'); + $insights = function_exists('pbpe_insight_browse_url') ? pbpe_insight_browse_url() : ''; + + if ('' === $systems) { + $systems = isset($structural['systems']) ? (string) $structural['systems'] : ''; + } + + if ('' === $education) { + $education = pbpe_home_template_url('page-templates/education-landing.php'); + } + + if ('' === $education) { + $education = isset($structural['education']) ? (string) $structural['education'] : ''; + } + + if ('' === $brands) { + $brands = isset($structural['brands']) ? (string) $structural['brands'] : ''; + } + + if ('' === $insights) { + $insights = pbpe_home_template_url('page-templates/insights-landing.php'); + } + + if ('' === $insights) { + $insights = isset($structural['insights']) ? (string) $structural['insights'] : ''; + } + + return array( + 'equipment' => isset($structural['shop']) ? (string) $structural['shop'] : '', + 'systems' => $systems, + 'education' => $education, + 'brands' => $brands, + 'insights' => $insights, + 'trade' => isset($structural['trade']) ? (string) $structural['trade'] : '', + 'contact' => isset($structural['contact']) ? (string) $structural['contact'] : '', + ); +} + +/** + * Resolve one existing term by its approved stable slug. + */ +function pbpe_home_term(string $taxonomy, string $slug): ?WP_Term { + if (! taxonomy_exists($taxonomy)) { + return null; + } + + $term = get_term_by('slug', $slug, $taxonomy); + + return $term instanceof WP_Term ? $term : null; +} + +/** + * Approved application presentation with dynamic taxonomy names and URLs. + * + * @return array + */ +function pbpe_home_application_paths(string $shop): array { + $approved = array( + 'strength-power' => array( + 'title' => 'Strength & Power', + 'body' => 'Build strength, power and resilient movement.', + 'layout' => 'lead', + 'image_field' => 'pbpe_home_application_strength_image', + 'alt' => 'Athlete performing a loaded ViPR movement in a gym', + 'crop' => 'strength', + ), + 'mobility-movement' => array( + 'title' => 'Mobility & Movement', + 'body' => 'Develop mobility, control and movement quality.', + 'layout' => 'portrait', + 'image_field' => 'pbpe_home_application_mobility_image', + 'alt' => 'Group using Stick Mobility training sticks in a lateral reach', + 'crop' => 'mobility', + ), + 'functional-training' => array( + 'title' => 'Functional Training', + 'body' => 'Train integrated movement for real-world and athletic performance.', + 'layout' => 'standard', + 'image_field' => 'pbpe_home_application_functional_image', + 'alt' => 'Bare foot training on Naboso textured wedges', + 'crop' => 'functional', + ), + 'speed-agility' => array( + 'title' => 'Speed & Agility', + 'body' => 'Develop acceleration, reaction and multidirectional movement.', + 'layout' => 'standard', + 'image_field' => 'pbpe_home_application_speed_image', + 'alt' => 'Athletes reaching for BlazePod reaction lights', + 'crop' => 'speed', + ), + 'recovery' => array( + 'title' => 'Recovery', + 'body' => 'Support recovery, tissue care and movement preparation.', + 'layout' => 'standard', + 'image_field' => 'pbpe_home_application_recovery_image', + 'alt' => 'Athlete using a Tune Up Fitness therapy ball against a wall', + 'crop' => 'recovery', + ), + ); + + $paths = array(); + + foreach ($approved as $slug => $presentation) { + $term = pbpe_home_term('pbpe_application', $slug); + + $presentation['url'] = ''; + + if ($term instanceof WP_Term) { + if ('' !== $shop) { + $presentation['url'] = add_query_arg(array('application' => array($term->slug)), $shop); + } } + + $paths[] = $presentation; } - return $education; + return $paths; } /** - * Application terms that already classify products. No terms are created. + * Dynamic ViPR PRO System content and permalink. * - * @return array + * @return array */ -function pbpe_home_applications(): array { - if (! taxonomy_exists('pbpe_application')) { - return array(); +function pbpe_home_featured_system(): array { + $system = post_type_exists('pbpe_system') ? get_page_by_path('vipr-pro', OBJECT, 'pbpe_system') : null; + + if (! $system instanceof WP_Post || 'publish' !== $system->post_status) { + $systems = function_exists('pbpe_system_posts') ? pbpe_system_posts() : array(); + + foreach ($systems as $candidate) { + if ($candidate instanceof WP_Post && 0 === strcasecmp(trim(get_the_title($candidate)), 'ViPR PRO')) { + $system = $candidate; + break; + } + } + } + + $title = 'ViPR PRO'; + $body = 'Integrate strength, movement and function through a training system designed for whole-body movement.'; + $url = ''; + + if ($system instanceof WP_Post && 'publish' === $system->post_status) { + $dynamic_title = trim(get_the_title($system)); + $dynamic_body = trim((string) $system->post_excerpt); + $dynamic_url = get_permalink($system); + + $title = '' !== $dynamic_title ? $dynamic_title : $title; + $body = '' !== $dynamic_body ? $dynamic_body : $body; + $url = is_string($dynamic_url) ? $dynamic_url : ''; } - $terms = get_terms( + return array( + 'title' => $title, + 'body' => $body, + 'url' => $url, + ); +} + +/** + * Approved Education pathways with dynamic catalogue filters. + * + * @return array + */ +function pbpe_home_education_paths(string $catalogue): array { + $paths = array( array( - 'taxonomy' => 'pbpe_application', - 'hide_empty' => true, - ) + 'index' => '01', + 'label' => 'Course', + 'title' => 'Courses', + 'body' => 'Flexible professional learning designed to build practical knowledge and expand your capability.', + ), + array( + 'index' => '02', + 'label' => 'Certification', + 'title' => 'Certifications', + 'body' => 'Structured education pathways for professionals looking to develop specialist skills and recognised expertise.', + ), ); - if (! is_array($terms) || is_wp_error($terms)) { - return array(); + foreach ($paths as &$path) { + $slug = function_exists('pbpe_education_term_slug') ? pbpe_education_term_slug('pa_education-type', $path['label']) : ''; + $path['url'] = '' !== $catalogue && '' !== $slug ? add_query_arg('education-type', $slug, $catalogue) : $catalogue; + unset($path['label']); } + unset($path); - $applications = array(); + return $paths; +} + +/** + * Approved brand selection with dynamic names and term links. + * + * @return array + */ +function pbpe_home_selected_brands(): array { + $approved = array( + 'vipr-pro' => array('name' => 'ViPR PRO', 'descriptor' => 'Movement training'), + 'stick-mobility' => array('name' => 'Stick Mobility', 'descriptor' => 'Mobility + movement'), + 'naboso' => array('name' => 'Naboso', 'descriptor' => 'Sensory movement'), + 'tune-up-fitness' => array('name' => 'Tune Up Fitness', 'descriptor' => 'Mobility + self-care'), + 'perform-better' => array('name' => 'Perform Better', 'descriptor' => 'Professional training equipment'), + ); + $brands = array(); + + foreach ($approved as $slug => $presentation) { + $term = pbpe_home_term('product_brand', $slug); + $name = $presentation['name']; + $url = ''; - foreach ($terms as $term) { if ($term instanceof WP_Term) { - $applications[] = $term; + $name = $term->name; + $term_url = get_term_link($term); + $url = is_string($term_url) && ! is_wp_error($term_url) ? $term_url : ''; } + + $brands[] = array( + 'slug' => $slug, + 'name' => $name, + 'descriptor' => $presentation['descriptor'], + 'url' => $url, + ); + } + + return $brands; +} + +/** + * Approved Insight topics with dynamic term names and links. + * + * @return array + */ +function pbpe_home_insight_topics(): array { + $approved = array( + 'movement-training' => array( + 'index' => '01', + 'title' => 'Movement & training', + 'body' => 'Principles, perspectives and practical thinking for movement and training.', + 'image_field' => 'pbpe_home_insight_movement_image', + 'alt' => 'Athlete in a dynamic lateral lunge coached by a trainer in the gym', + 'crop' => 'movement', + ), + 'coaching-practice' => array( + 'index' => '02', + 'title' => 'Coaching & practice', + 'body' => 'Ideas for coaching, communication and applying knowledge with people.', + 'image_field' => 'pbpe_home_insight_coaching_image', + 'alt' => 'Practitioner coaching a kneeling client through a loaded movement', + 'crop' => 'coaching', + ), + 'professional-learning' => array( + 'index' => '03', + 'title' => 'Professional learning', + 'body' => 'Ideas and perspectives that support continued learning and professional development.', + 'image_field' => 'pbpe_home_insight_learning_image', + 'alt' => 'Older athlete squatting with a medicine ball while coached by a trainer', + 'crop' => 'learning', + ), + ); + $topics = array(); + + foreach ($approved as $slug => $presentation) { + $term = pbpe_home_term('pbpe_insight_topic', $slug); + $presentation['url'] = ''; + + if ($term instanceof WP_Term) { + $url = get_term_link($term); + $presentation['title'] = '' !== trim($term->name) ? $term->name : $presentation['title']; + $presentation['url'] = is_string($url) && ! is_wp_error($url) ? $url : ''; + } + + $topics[] = $presentation; } - return $applications; + return $topics; } ``` END CHUNK 4 OF 4

Our philosophy

More than equipment

The right equipment is only part of the equation. Perform Better Pro-Ed brings together professional tools, movement systems and education to help people understand not only what to use, but how to use it.

Equipment

01

Equipment

Professional tools selected for movement, training, recovery and assessment.

Shop Equipment
Coach observing an athlete stepping through an FMS movement screen

02

Systems

Explore the methods, applications and education behind the equipment.

Explore Systems
Presenter teaching a professional education session with audience and presentation screen

03

Education

Build practical knowledge through courses, certifications and workshops.

Explore Education

Training systems

The tool is only
the beginning

Great equipment becomes more valuable when you understand how to apply it. Explore training systems that bring together the tool, the methodology and the education behind it.

01

Methodology

Understand the principles and thinking behind the tool.

02

Application

Learn how to apply equipment effectively across movement and training.

03

Education

Build the knowledge and practical skills to use the system with purpose.

Professional education

Learn Apply Perform

Professional education designed to turn knowledge into practice. Explore courses and certifications that help movement and health professionals build practical skills they can use with the people they work with.

Explore Education
Instructor coaching a participant through a Stick Mobility workshop drill

Selected brands

Tools we believe in

We work with established movement and performance brands chosen for the quality of their products, the thinking behind them and their relevance to professional practice.

View all brands

Insights

Think better Move better

Practical thinking for movement and health professionals. Explore articles, research, expert perspectives and ideas designed to inform better practice.

View all insights
Movement and performance

01

Movement & training

Principles, perspectives and practical thinking for movement and training.

Practitioner coaching a kneeling client through a loaded movement

02

Coaching & practice

Ideas for coaching, communication and applying knowledge with people.

Older athlete squatting with a medicine ball while coached by a trainer

03

Professional learning

Ideas and perspectives that support continued learning and professional development.

Coach assisting an athlete through a cable and band movement

For professionals

Built for peoplewho move people

From individual practitioners to studios, clinics and performance facilities, Perform Better Pro-Ed supports professionals with equipment, training systems, education and practical expertise.