<?php
$form = Yii::app()->getController()->beginWidget('CActiveForm', array(
    'id' => 'newsletter-subscriber-form',
    'action' => Yii::app()->createUrl('newsletterSubscriber/create'),
    // Please note: When you enable ajax validation, make sure the corresponding
    // controller action is handling ajax validation correctly.
    // There is a call to performAjaxValidation() commented in generated controller code.
    // See class documentation of CActiveForm for details on this.
    'enableAjaxValidation' => true,
    'clientOptions' => array(
        'validateOnChange' => false,
        'validateOnSubmit' => false,
    ),
        ));
?>



<?php echo $form->errorSummary($model); ?>



<?php echo $form->label($model, 'email', array('label' => Yii::t('site', 'Put your email and you will receive all news'))); ?>

<div class="relative">

    <div class="row">
        <?php echo $form->textField($model, 'email', array('class' => 'email-field', 'maxlength' => 50, 'placeholder' => 'Send your email ...')); ?>

        <?php echo $form->error($model, 'email'); ?>
    </div>


    <?php // echo CHtml::submitButton($model->isNewRecord ? 'Create' : 'Save',array('class'=>'submit'));   ?>

</div>

<!-- Modal -->

<div id="newsletter-container" class="flexcms-modal-container">

    <div id="newsletterModal" class="modal hide fade" tabindex="-1" role="dialog" aria-hidden="true" data-backdrop="false" >

        <div class="modal-header">

            <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>

        </div>

        <div class="modal-body"></div>

    </div>

</div>

<?php Yii::app()->getController()->endWidget(); ?>