Example #1
0
<?php

/* ==== TEMPLATE ============================================= */
$classes = array('button');
if (!empty($has_arrow)) {
    $classes[] = 'has-arrow';
}
echo sprintfLink($link, $text, implode(' ', $classes));
?>

/* ==== TO ADD ============================================= */
	'button' => array(
		'fields' => array(
			'text' => array(),
			'link' => array(
				'type' => 'link'
			),
			'has_little_arrow' => array(
				'type' => 'checkbox',
				'title' => '',
				'checkbox_label' => 'Has Little Arrow'
			)
		)
	)
Example #2
0
    return;
}
?>
<ul class="items-list">
	<?php 
foreach ($items as $item) {
    if (!$item['text']) {
        continue;
    }
    ?>
		<li class="item">
		<?php 
    if ($item['link']['url']) {
        ?>
			<?php 
        echo sprintfLink($item['link'], $item['text']);
        ?>
		<?php 
    } else {
        ?>
			<span class="no-link"><?php 
        echo $item['text'];
        ?>
</span>
		<?php 
    }
    ?>
		</li>
	<?php 
}
?>
Example #3
0
<?php 
if (!$boxes) {
    return;
}
?>
<div class="price-boxes number-<?php 
echo sizeof($boxes);
?>
 cf">
	<?php 
$default_button = !empty($default_button['url']) ? sprintfLink($default_button, $default_button['title'], 'button color-orange') : false;
foreach ($boxes as $box) {
    if (empty($box['button']['url'])) {
        $button = $default_button;
    } else {
        $button = sprintfLink($box['button'], $box['button']['title'], 'button color-orange');
    }
    $classes = array('price-box');
    if (!empty($box['is_featured'])) {
        $classes[] = 'featured';
    }
    ?>
		<div class="<?php 
    echo implode(' ', $classes);
    ?>
">
			<h3 class="title"><?php 
    echo $box['title'];
    ?>
</h3>
			<div class="price">