Empower marketing teams to build dynamic, multi-section landing pages from design-system approved blocks. Clean PHP templating, lightning-fast Core Web Vitals, and total theme independence.
Site builders like Elementor and Divi lock clients into sluggish HTML markup and brittle proprietary ecosystems. MetaForge Flexible Content lets you build a bespoke design system with 100% code ownership.
Define unlimited distinct layout blocks: Hero Sections, Split Grids, Testimonial Sliders, Call to Action ribbons, and Pricing Matrices.
Bespoke Design SystemZero page builder scripts or redundant DOM wrappers. Output only the lean semantic HTML, CSS, and SVG icons you craft yourself.
Maximum SEO SpeedPrevent accidental design breakage. Marketing editors can only choose from your approved layouts and curated styling options.
Editorial GuardrailsRearrange entire page sections instantly. Move your pricing table above your testimonials with one fluid drag action.
Effortless Editorial UXEnforce structural rules per layout (e.g. limit Hero Banners to 1 per page, but allow up to 10 Content Sections).
Layout Rules EngineUse MetaForge's AI Assistant to auto-generate entire flexible content schemas and field blueprints in seconds.
AI Powered GenerationStructuring flexible content in WordPress requires two simple pieces: a main page layout switcher loop, and modular component partials.
This template iterates through active sections and delegates each layout to its respective partial.
<?php
/**
* Clean Modular Page Builder Template
* File: page-builder.php (Page Template)
*/
get_header(); ?>
<main id="primary" class="site-main">
<?php
// Check if the page has flexible content rows
if (metaforge_have_rows('page_sections')) :
while (metaforge_have_rows('page_sections')) : metaforge_the_row();
// Get current active layout slug (e.g. 'hero_banner', 'pricing_table', 'testimonials')
$layout_name = metaforge_get_row_layout();
// Delegate rendering to component template partials
// Automatically searches for: template-parts/layouts/{$layout_name}.php
get_template_part('template-parts/layouts/' . $layout_name);
endwhile;
metaforge_reset_rows();
else :
// Fallback for standard WordPress editor content
the_content();
endif;
?>
</main>
<?php get_footer(); ?>Each component handles only its own HTML and scoped styling, making your codebase modular and maintainable.
<?php
/**
* Component Layout: Hero Banner
* File: template-parts/layouts/hero_banner.php
*/
$headline = metaforge_get_sub_field('hero_headline');
$tagline = metaforge_get_sub_field('hero_tagline');
$cta_text = metaforge_get_sub_field('cta_button_text');
$cta_url = metaforge_get_sub_field('cta_button_url');
$bg_image_id = metaforge_get_sub_field('background_image');
?>
<section class="modular-hero-banner" style="position:relative;">
<?php if (!empty($bg_image_id)) : ?>
<div class="hero-bg-layer">
<?php echo wp_get_attachment_image($bg_image_id, 'full', false, ['loading' => 'eager']); ?>
</div>
<?php endif; ?>
<div class="container">
<h1><?php echo esc_html($headline); ?></h1>
<p class="hero-tagline"><?php echo esc_html($tagline); ?></p>
<?php if (!empty($cta_url) && !empty($cta_text)) : ?>
<a href="<?php echo esc_url($cta_url); ?>" class="btn btn-hero">
<?php echo esc_html($cta_text); ?> →
</a>
<?php endif; ?>
</div>
</section>Answers to common developer questions about WordPress flexible content architecture.
Explore other specialized custom field tools in MetaForge Engine.
Admin & Customer Account Portal
Activate your Pro license key and customer portal