Ejemplo n.º 1
0
    public function subscription_form($model, $action = "", $handle = false, $show_name_field = true, $extra1 = false, $extra2 = false, $image_submit = false)
    {
        if (!$handle) {
            $handle = "all_sections";
        }
        $form = '<div id="subscription-form">
							<form action="' . $action . '" method="post" class="form_container">' . hidden_field($model, "handle", array('value' => $handle)) . hidden_field($model, "status", array('value' => 1)) . '<fieldset>';
        if ($show_name_field) {
            $form .= large(text_field($model, "name", array(), "Name <span class='mandatory'>*</span>")) . form_divider();
        }
        $form .= large(text_field($model, "email", array(), "Email <span class='mandatory'>*</span>"));
        if ($extra1) {
            $form .= form_divider() . large(text_field($model, "extra1", array(), $extra1));
        }
        if ($extra2) {
            $form .= form_divider() . large(text_field($model, "extra2", array(), $extra2));
        }
        $form .= form_divider() . '<span id="mandatory">* Compulsory fields</span>';
        if ($image_submit) {
            $form .= image_submit_tag($image_submit, array('alt' => "submit button", "title" => "Submit"));
        } else {
            $form .= small(submit_field($model, "Subscribe"));
        }
        $form .= '</fieldset>
					 		</form>							
						</div>';
        return $form;
    }
Ejemplo n.º 2
0
						<?php 
foreach (TBGCustomDatatype::getAll() as $customdatatype) {
    ?>
							<option value="<?php 
    echo $customdatatype->getKey();
    ?>
"><?php 
    echo __($customdatatype->getDescription());
    ?>
</option>
						<?php 
}
?>
					</select>
					<?php 
echo image_submit_tag('action_add_small.png');
?>
					<?php 
echo image_tag('spinning_16.gif', array('style' => 'margin-left: 5px; display: none;', 'id' => 'add_filter_indicator'));
?>
					<div class="faded_out" style="padding: 10px 0 5px 0;"><?php 
echo __('Adding the same filter more than once means that any of the given values for that filter will return a match if you are matching with "is", and neither of the given values if you are matching with "is not"');
?>
</div>
				</form>
			</div>
			<?php 
if ($show_results) {
    ?>
				<div class="main_header">
					<?php