Hi!
I’m trying to submit a form using ajaxSubmitButton, but instead it submits as if there was a normal submit.
Here’s the code from the view file:
<?php
$form = $this->beginWidget('CActiveForm', array(
'id' => 'msg-messages-index-form',
'enableAjaxValidation' => false,
));
?>
<?= $form->errorSummary($replymessage); ?>
<div class="row rel-container replymessagetext">
<?= $form->textArea($replymessage, 'text', array('class' => 'overlayed')); ?>
<?= $form->label($replymessage, 'text', array('class' => 'label-overlay')); ?>
</div>
<div class="row buttons replymessagebuttons">
<?=
CHtml::ajaxSubmitButton(
'Send',
'/messages/reply',
array(
'update' => '#' . $thread_id . ' .replyform',
'type' => 'POST',
),
array('class' => 'greybutton')
)
?>
</div>
<?php $this->endWidget(); ?>
I’ve been stuck with this for couple of hours now and just can’t find what’s causing this problem.
What could be wrong here?