だから私はYii-userとYii-bootstrapを持っています。ユーザーがメインページで何かをクリックしたときに、モーダルダイアログで登録フォームをロードしたいと思います。すべてのコントローラーのアクションでクラスをロードしました。
$this->beginWidget('bootstrap.widgets.BootModal', array('id'=>'logonDialog')); ?>
<div class="modal-header">
<a class="close" data-dismiss="modal">×</a>
<h3>Inscription ou Connexion</h3></div>
<div class="modal-body">
<div class="row">
<div class="span6"><?php
$lmodel=new UserLogin;
$this->renderPartial('application.modules.user.views.user.login',array('model'=>$lmodel,));
?></div>
<div class="span6">
<?
$rmodel = new RegistrationForm;
$rprofile=new Profile;
$this->renderPartial('application.modules.user.views.user.registration',array('model'=>$rmodel,'profile'=>$rprofile));
?>
</div>
</div>
</div>
<div class="modal-footer"></div>
<?php $this->endWidget();
ログインフォームは正常に機能していますが、これに関する唯一の問題は、登録フォームにキャプチャがなく、ログにエラーが表示されることです。
2012/07/14 12:37:28 [warning] [application] Failed to set unsafe attribute "verifyCode" of "RegistrationForm".
in /home/something/protected/modules/user/controllers/RegistrationController.php (29)
in /home/something/public_html/test.php (15)
2012/07/14 12:37:32 [warning] [application] Failed to set unsafe attribute "verifyCode" of "RegistrationForm".
in /home/something/protected/modules/user/controllers/RegistrationController.php (29)
in /home/something/public_html/test.php (15)
2012/07/14 12:37:38 [warning] [application] Failed to set unsafe attribute "verifyCode" of "RegistrationForm".
in /home/something/protected/modules/user/controllers/RegistrationController.php (29)
in /home/something/public_html/test.php (15)
2012/07/14 12:37:41 [warning] [application] Failed to set unsafe attribute "verifyCode" of "RegistrationForm".
in /home/something/protected/modules/user/controllers/RegistrationController.php (29)
in /home/something/public_html/test.php (15)
2012/07/14 12:37:42 [warning] [application] Failed to set unsafe attribute "verifyCode" of "RegistrationForm".
in /home/something/protected/modules/user/controllers/RegistrationController.php (29)
in /home/something/public_html/test.php (15)
2012/07/14 12:37:48 [warning] [application] Failed to set unsafe attribute "verifyCode" of "RegistrationForm".
in /home/something/protected/modules/user/controllers/RegistrationController.php (29)
in /home/something/public_html/test.php (15)
2012/07/14 12:38:01 [warning] [application] Failed to set unsafe attribute "verifyCode" of "RegistrationForm".
in /home/something/protected/modules/user/controllers/RegistrationController.php (29)
in /home/something/public_html/test.php (15)
2012/07/14 12:38:04 [warning] [application] Failed to set unsafe attribute "verifyCode" of "RegistrationForm".
in /home/something/protected/modules/user/controllers/RegistrationController.php (29)
in /home/something/public_html/test.php (15)
2012/07/14 12:38:13 [warning] [application] Failed to set unsafe attribute "verifyCode" of "RegistrationForm".
in /home/something/protected/modules/user/controllers/RegistrationController.php (29)
in /home/something/public_html/test.php (15)
2012/07/14 12:38:14 [warning] [application] Failed to set unsafe attribute "verifyCode" of "RegistrationForm".
in /home/something/protected/modules/user/controllers/RegistrationController.php (29)
in /home/something/public_html/test.php (15)
2012/07/14 12:38:14 [warning] [application] Failed to set unsafe attribute "verifyCode" of "RegistrationForm".
in /home/something/protected/modules/user/controllers/RegistrationController.php (37)
in /home/something/public_html/test.php (15)
2012/07/14 12:44:56 [error] [exception.CHttpException.404] exception 'CHttpException' with message 'Le système ne peut trouver l'action « captcha » demandée.' in /home/something/yii/framework/web/CController.php:484
Stack trace:
#0 /home/something/yii/framework/web/CController.php(271): CController->missingAction('captcha')
#1 /home/something/yii/framework/web/CWebApplication.php(276): CController->run('captcha')
#2 /home/something/yii/framework/web/CWebApplication.php(135): CWebApplication->runController('user/login/capt...')
#3 /home/something/yii/framework/base/CApplication.php(162): CWebAp