Esempio n. 1
0
		</div>

		<div class="row-fluid">
			<?php 
echo $form->labelEx($ContactForm, 'contactBody');
?>
			<?php 
echo $form->textArea($ContactForm, 'contactBody', array('rows' => 4, 'cols' => 180));
?>
			<?php 
echo $form->error($ContactForm, 'contactBody');
?>
		</div>

		<?php 
if (_xls_show_captcha('contactus') && CCaptcha::checkRequirements()) {
    ?>
			<div class="row-fluid">
				<?php 
    echo $form->labelEx($ContactForm, 'verifyCode');
    ?>
				<div>
					<?php 
    $this->widget('CCaptcha');
    ?>
					<?php 
    echo $form->textField($ContactForm, 'verifyCode');
    ?>
				</div>
				<div class="hint">Please enter the letters as they are shown in the image above.
					<br/>Letters are not case-sensitive.</div>
Esempio n. 2
0
 /**
  * Declares the validation rules.
  */
 public function rules()
 {
     return array(array('fromName, fromEmail', 'validateFrom'), array('contactSubject, contactBody', 'required'), array('fromEmail', 'email'), array('verifyCode', 'captcha', 'allowEmpty' => !(_xls_show_captcha('contactus') && CCaptcha::checkRequirements())));
 }