<div id="stickycta" class="sticky-cta">
    <div class="sticky-cta__inner">
        <div class="sticky-cta__link">
            <a href="#1" class="cta cta--primary" target="_blank">
              <span class="cta__label">
                  Find out how we solve problems
                  <svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
                      <g fill-rule="evenodd">
                      <path d="M9.238 0v8.527L7.04 7.856 5.913 9.363l3.497 5.31h1.669l3.497-5.31-1.128-1.507-2.21.676V0z"/>
                      <path d="M18 11.094v7H2v-7H0v8l1 1h18l1-1v-8z"/>
                      </g>
                  </svg>
              </span>
          </a>
        </div>
    </div>
</div>
  • Content:
    <?php
    $stickycta = array (
      'key' => 'stickyctafield',
      'label' => 'Sticky CTA',
      'name' => 'sticky-cta-block',
      'type' => 'text',
      'sub_fields' => array (
        array(
    			'key' => 'field_5c07e8ff28e61',
    			'label' => 'CTA text',
    			'name' => 'label',
    			'type' => 'text',
    			'instructions' => '',
    			'required' => 1,
    			'conditional_logic' => 0,
    			'wrapper' => array(
    				'width' => '',
    				'class' => '',
    				'id' => '',
    			),
    			'default_value' => '',
    			'placeholder' => '',
    			'prepend' => '',
    			'append' => '',
    			'maxlength' => '',
    		),
    		array(
    			'key' => 'field_5c07e93028e62',
    			'label' => 'CTA type',
    			'name' => 'type',
    			'type' => 'select',
    			'instructions' => '',
    			'required' => 1,
    			'conditional_logic' => 0,
    			'wrapper' => array(
    				'width' => '',
    				'class' => '',
    				'id' => '',
    			),
    			'choices' => array(
    				'Link' => 'Link',
    				'Download' => 'Download',
    			),
    			'default_value' => array(
    			),
    			'allow_null' => 0,
    			'multiple' => 0,
    			'ui' => 0,
    			'return_format' => 'value',
    			'ajax' => 0,
    			'placeholder' => '',
    		),
    		array(
    			'key' => 'field_5c07e95f28e63',
    			'label' => 'CTA link url',
    			'name' => 'url',
    			'type' => 'link',
    			'instructions' => '',
    			'required' => 0,
    			'conditional_logic' => array(
    				array(
    					array(
    						'field' => 'field_5c07e93028e62',
    						'operator' => '==',
    						'value' => 'Link',
    					),
    				),
    			),
    			'wrapper' => array(
    				'width' => '',
    				'class' => '',
    				'id' => '',
    			),
    			'return_format' => 'url',
    		),
    		array(
    			'key' => 'field_5c07e99b28e64',
    			'label' => 'Download',
    			'name' => 'download',
    			'type' => 'file',
    			'instructions' => '',
    			'required' => 0,
    			'conditional_logic' => array(
    				array(
    					array(
    						'field' => 'field_5c07e93028e62',
    						'operator' => '==',
    						'value' => 'Download',
    					),
    				),
    			),
    			'wrapper' => array(
    				'width' => '',
    				'class' => '',
    				'id' => '',
    			),
    			'return_format' => 'url',
    			'library' => 'all',
    			'min_size' => '',
    			'max_size' => '',
    			'mime_types' => '',
    		),
    	),
    	'location' => array(
    		array(
    			array(
    				'param' => 'post_type',
    				'operator' => '==',
    				'value' => 'post',
    			),
    		),
    	),
    	'menu_order' => 0,
    	'position' => 'normal',
    	'style' => 'default',
    	'label_placement' => 'top',
    	'instruction_placement' => 'label',
    	'hide_on_screen' => '',
    	'active' => 1,
    	'description' => '',
    );
    
    array_push($_SESSION["blocks"], $stickycta);
  • URL: /components/raw/sticky-cta-block/sticky-cta-block.php
  • Filesystem Path: src/components/cms-blocks/sticky-cta-block/sticky-cta-block.php
  • Size: 2.4 KB