HEX
Server: Microsoft-IIS/8.5
System: Windows NT YDAWBH120 6.3 build 9600 (Windows Server 2012 R2 Standard Edition) AMD64
User: tentjecom_web (0)
PHP: 7.4.14
Disabled: NONE
Upload Files
File: D:/HostingSpaces/MDalebout3/dev.prdct.nl/wwwroot/wp-content/themes/theme/blocks/block-top-title.php
    <?php

    /**
     * Sublogo Block Template.
     *
     * @param   array $block The block settings and attributes.
     * @param   string $content The block inner HTML (empty).
     * @param   bool $is_preview True during AJAX preview.
     * @param   (int|string) $post_id The post ID this block is saved to.
     */

    // Create id attribute allowing for custom "anchor" value.
    $id = 'top-title-' . $block['id'];
    if( !empty($block['anchor']) ) {
        $id = $block['anchor'];
    }

    // Create class attribute allowing for custom "className" and "align" values.
    $className = 'top-title';
    if( !empty($block['className']) ) {
        $className .= ' ' . $block['className'];
    }
    if( !empty($block['align']) ) {
        $className .= ' align' . $block['align'];
    }

    // Load values and assign defaults.
    $toptitle = get_field('top_title') ?: __('Title');
    $topdescr = get_field('top_description') ?: __('Description');
    ?>

    <section class="block-half-circle">
        <div class="section-inner">
            <h1 class="bhc-heading"><?php echo $toptitle; ?></h1>
            <h3 class="bhc-text"><?php echo $topdescr; ?></h3>
        </div>
    </section>