marciocamello/yii2-mcms-ajax-form

Ajax form with malsup jquery-form

dev-master 2014-04-29 17:10 UTC

This package is not auto-updated.

Last update: 2024-04-09 04:27:09 UTC


README

Ajax form with malsup jquery-form

Installation

The preferred way to install this extension is through composer.

Either run

php composer.phar require --prefer-dist marciocamello/yii2-mcms-ajax-form "*"

or add

"marciocamello/yii2-mcms-ajax-form": "*"

to the require section of your composer.json file.

Usage

Once the extension is installed, simply use it in your code by :

<?php
  $form = \mcms\ajaxform\AjaxActiveForm::begin([
					'id' => 'register-form',
					'options'=>[
						'enctype'=>'multipart/form-data'
					],
					'modal' => true,
					'modalOptions' => [
						'header' => false,
					],
					'pluginOptions' => [
						'resetForm' => false,
					],
				]);
?>

Your form objects here.
				
<?php \mcms\ajaxform\AjaxActiveForm::end();?>