當前位置: 首頁>>代碼示例>>PHP>>正文


PHP CHtml::endForm方法代碼示例

本文整理匯總了PHP中CHtml::endForm方法的典型用法代碼示例。如果您正苦於以下問題:PHP CHtml::endForm方法的具體用法?PHP CHtml::endForm怎麽用?PHP CHtml::endForm使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在CHtml的用法示例。


在下文中一共展示了CHtml::endForm方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: renderContent

 /**
  * (non-PHPdoc)
  * @see CPortlet::renderContent()
  */
 protected function renderContent()
 {
     $themesList = array_combine(Yii::app()->themeManager->themeNames, Yii::app()->themeManager->themeNames);
     echo CHtml::form('', 'post', array());
     echo CHtml::dropDownList('themeSelector', Yii::app()->theme->name, $themesList, $this->dropDownOptions);
     echo CHtml::endForm();
 }
開發者ID:jackycgq,項目名稱:advanced,代碼行數:11,代碼來源:EThemePicker.php

示例2: formButton

 /**
  * @param array $options
  * @return string
  */
 public function formButton($options = array())
 {
     $form = CHtml::beginForm($this->url(), 'get');
     $form .= CHtml::hiddenField('business', $this->business);
     foreach (CMap::mergeArray($this->defaultOptions, $options) as $k => $v) {
         $form .= CHtml::hiddenField($k, $v);
     }
     $form .= CHtml::imageButton($this->image, array('border' => 0, 'alt' => $this->imageAltText));
     $form .= CHtml::endForm();
     return $form;
 }
開發者ID:cornernote,項目名稱:yii-dressing,代碼行數:15,代碼來源:YdPayPalHelper.php

示例3: renderContent

 /**
  * (non-PHPdoc)
  * @see CPortlet::renderContent()
  */
 protected function renderContent()
 {
     $translations = self::getLanguagesList();
     echo CHtml::form('', 'post', array());
     echo CHtml::dropDownList('languageSelector', Yii::app()->getLanguage(), $translations, $this->dropDownOptions);
     echo CHtml::endForm();
 }
開發者ID:rusli-nasir,項目名稱:ERP_Accounting_Indonesia,代碼行數:11,代碼來源:ELanguagePicker.php

示例4: renderCheckoutForm

 public function renderCheckoutForm(Payment $payment, Order $order, $return = false)
 {
     $settings = $payment->getPaymentSystemSettings();
     $mrhLogin = $settings['login'];
     $mrhPass1 = $settings['password1'];
     $culture = $settings['language'];
     $invId = $order->id;
     $invDesc = Yii::t('RobokassaModule.robokassa', 'Payment order #{id} on "{site}" website', ['{id}' => $order->id, '{site}' => Yii::app()->getModule('yupe')->siteName]);
     $outSum = Yii::app()->money->convert($order->getTotalPrice(), $payment->currency_id);
     $crc = md5("{$mrhLogin}:{$outSum}:{$invId}:{$mrhPass1}");
     $form = CHtml::form($settings['testmode'] ? "http://test.robokassa.ru/Index.aspx" : "https://merchant.roboxchange.com/Index.aspx");
     $form .= CHtml::hiddenField('MrchLogin', $mrhLogin);
     $form .= CHtml::hiddenField('OutSum', $outSum);
     $form .= CHtml::hiddenField('InvId', $invId);
     $form .= CHtml::hiddenField('Desc', $invDesc);
     $form .= CHtml::hiddenField('SignatureValue', $crc);
     $form .= CHtml::hiddenField('Culture', $culture);
     $form .= CHtml::submitButton(Yii::t('RobokassaModule.robokassa', 'Pay'));
     $form .= CHtml::endForm();
     if ($return) {
         return $form;
     } else {
         echo $form;
     }
 }
開發者ID:RonLab1987,項目名稱:43berega,代碼行數:25,代碼來源:RobokassaPaymentSystem.php

示例5: endForm

 public function endForm()
 {
     echo CHtml::closeTag('fieldset');
     if ($this->form) {
         echo CHtml::endForm();
     }
 }
開發者ID:sickpig,項目名稱:LimeSurvey,代碼行數:7,代碼來源:SettingsWidget.php

示例6: endForm

 public function endForm()
 {
     if ($this->form) {
         echo CHtml::endForm();
     } else {
         echo CHtml::closeTag('div');
     }
 }
開發者ID:josetorerobueno,項目名稱:test_repo,代碼行數:8,代碼來源:SettingsWidget.php

示例7: form

function form($name, $label, $action, $dis = array())
{
    echo CHtml::beginForm('', 'POST');
    echo CHtml::submitButton($label, $dis + array('style' => 'float: left'));
    echo CHtml::hiddenField('action', $action);
    echo CHtml::hiddenField('name', $name);
    echo CHtml::endForm();
}
開發者ID:Jmainguy,項目名稱:multicraft_install,代碼行數:8,代碼來源:bgPlugin.php

示例8: headEnableAjax

 public function headEnableAjax()
 {
     echo CHtml::beginForm();
     echo CHtml::openTag('label', array('class' => 'checkbox pull-right', 'style' => 'margin:5px 10px 0px 0px;', 'for' => 'ajaxUpdate'));
     echo "Aktifkan mode Ajax ";
     echo CHtml::Checkbox('ajaxUpdate', Yii::app()->user->getState('ajaxUpdate', true), array('uncheckValue' => 0, 'onclick' => "this.form.submit();"));
     echo CHtml::closetag("label");
     echo CHtml::endForm();
 }
開發者ID:beckblurry,項目名稱:Yii1-Base-Core-V.Alpha.1,代碼行數:9,代碼來源:CmsGridView.php

示例9: run

 public function run()
 {
     $placeholder = $this->type ? Yii::t('app', 'Search') . ' ' . ucfirst($this->type) . '...' : Yii::t('app', 'Search') . '...';
     echo CHtml::beginForm(array('/search/' . $this->type), 'get', array('class' => 'search-form'));
     echo CHtml::textField('q', $this->query, array('placeholder' => $placeholder));
     if ($this->query != '') {
         echo CHtml::submitButton('Search!', array('name' => ''));
     }
     echo CHtml::endForm('');
 }
開發者ID:awecode,項目名稱:awecms,代碼行數:10,代碼來源:SearchBlock.php

示例10: renderCsvButton

 public function renderCsvButton()
 {
     echo CHtml::beginForm(array('//user/csv/select'));
     foreach ($this->columns as $column) {
         if (isset($column->name)) {
             echo CHtml::hiddenField($column->name, $column->value);
         }
     }
     printf('<td>%s</td>', CHtml::submitButton('CSV'));
     echo CHtml::endForm();
 }
開發者ID:kumarsivarajan,項目名稱:yii-user-management,代碼行數:11,代碼來源:CsvGridView.php

示例11: endAdminTool

 public function endAdminTool()
 {
     if (Yii::app()->user->checkAccess('admin')) {
         echo "</div>";
         echo "<div id='dialog_" . $this->id . "' style='display:none;'>";
         echo CHtml::beginform(Yii::app()->createUrl('/core/admin/ajax/saveFile'), 'post', array('id' => "form_" . $this->id));
         $this->widget('ext.elrte.SElrteArea', array('name' => 'FileContent', 'value' => file_get_contents($this->filePath), 'htmlOptions' => array('cols' => 100, 'rows' => 15, 'id' => 'content_' . $this->id)));
         echo CHtml::hiddenField('FileName', $this->filePath);
         echo CHtml::endForm();
         echo "</div>";
     }
 }
開發者ID:bahdall,項目名稱:karbella_event,代碼行數:12,代碼來源:IncludeFile.php

示例12: run

 public function run()
 {
     $currencyActvie = Currency::getActiveCurrencyArray(2);
     $currentCharCode = Currency::getCurrentCurrencyModel()->char_code;
     foreach ($currencyActvie as $char_code => $currencyName) {
         echo CHtml::hiddenField($char_code, $this->getOwner()->createLangUrl(Yii::app()->language, array('currency' => $char_code)), array('id' => 'currency_' . $char_code));
     }
     echo CHtml::form();
     $class = Yii::app()->theme->name != 'classic' ? 'currency' : 'currency-drop';
     echo CHtml::dropDownList('currency', $currentCharCode, $currencyActvie, array('onchange' => 'this.form.action=$("#currency_"+this.value).val(); this.form.submit(); return false;', 'class' => $class));
     echo CHtml::endForm();
 }
開發者ID:barricade86,項目名稱:raui,代碼行數:12,代碼來源:currencySelectorWidget.php

示例13: sortOrder

 public function sortOrder($model, $ID)
 {
     $sortModel = $this->loadModelWidget($ID);
     echo CHtml::beginForm();
     $sort = array();
     for ($i = 1; $i <= count($model); $i++) {
         $sort[$i] = $i;
     }
     echo CHtml::hiddenField('WidgetSortID', $ID);
     echo CHtml::dropDownList('WidgetSortOrder', $sortModel->sort, $sort, array('class' => 'span4 pull-right', 'prompt' => '-Sort Order-', 'style' => 'margin-top:-40px;', 'onchange' => "this.form.submit();"));
     echo CHtml::endForm();
     echo "<br>";
 }
開發者ID:beckblurry,項目名稱:Yii1-Base-Core-V.Alpha.1,代碼行數:13,代碼來源:WidgetController.php

示例14: run

 /**
  *
  */
 public function run()
 {
     /** @var AccountModule $account */
     $account = Yii::app()->getModule('account');
     $cs = Yii::app()->getClientScript();
     $assetsUrl = $account->getAssetsUrl() . '/hybridAuth';
     $cs->registerCoreScript('jquery');
     $cs->registerCoreScript('jquery.ui');
     $cs->registerCssFile($cs->getCoreScriptUrl() . '/jui/css/base/jquery-ui.css');
     $cs->registerScriptFile($assetsUrl . '/script.js');
     $cs->registerCssFile($assetsUrl . '/styles.css');
     $cs->registerCssFile($assetsUrl . '/zocial/css/zocial.css');
     $providers = $account->hybridAuthConfig['providers'];
     echo '<div id="hybridauth-openid-div">';
     echo '<p>' . Yii::t('account', 'Enter your OpenID identity or provider:') . '</p>';
     echo CHtml::beginForm(Yii::app()->createUrl($this->baseUrl, array('returnUrl' => Yii::app()->returnUrl->getLinkValue(true))), 'get', array('id' => 'hybridauth-openid-form'));
     echo CHtml::hiddenField('provider', 'openid');
     echo CHtml::textField('openid_identifier');
     echo CHtml::endForm();
     echo '</div>';
     echo '<div id="hybridauth-confirm-unlink">';
     echo '<p>' . Yii::t('account', 'Are you sure you want to unlink this provider?') . '</p>';
     echo CHtml::beginForm(Yii::app()->createUrl($this->baseUrl, array('action' => 'unlink', 'returnUrl' => Yii::app()->returnUrl->getLinkValue(true))), 'post', array('id' => 'hybridauth-unlink-form'));
     echo CHtml::hiddenField('provider', '', array('id' => 'hybridauth-unlink-provider'));
     echo CHtml::endForm();
     echo '</div>';
     echo '<ul id="hybridauth-provider-list">';
     foreach ($providers as $provider => $settings) {
         if ($settings['enabled'] == true) {
             echo '<li>';
             echo CHtml::link(Yii::t('account', isset($settings['name']) ? $settings['name'] : $provider), array($this->baseUrl, 'provider' => $provider, 'returnUrl' => Yii::app()->returnUrl->getLinkValue(true)), array('id' => 'hybridauth-provider-' . strtolower($provider), 'class' => 'zocial ' . strtolower($provider)));
             echo '</li>';
         }
     }
     echo '</ul>';
     if (!Yii::app()->user->isGuest) {
         $userHybridAuths = CActiveRecord::model($account->userHybridAuthClass)->findAllByAttributes(array($account->userIdField => Yii::app()->user->id));
         if ($userHybridAuths) {
             echo '<h4>' . Yii::t('account', 'Linked Services') . '</h4>';
             echo '<ul id="hybridauth-account-list">';
             /** @var AccountUserHybridAuth[] $userHybridAuths */
             foreach ($userHybridAuths as $userHybridAuth) {
                 $provider = $userHybridAuth->{$account->providerField};
                 echo '<li>';
                 echo CHtml::link($userHybridAuth->{$account->emailField}, 'javascript:void(0);', array('id' => 'hybridauth-account-' . strtolower($provider), 'class' => 'zocial ' . strtolower($provider)));
                 echo '</li>';
             }
             echo '</ul>';
         }
     }
 }
開發者ID:cornernote,項目名稱:yii-account-module,代碼行數:54,代碼來源:AccountHybridAuthWidget.php

示例15: getHTML

 public static function getHTML()
 {
     $profilsList = array();
     foreach (Yii::app()->user->getState('profil') as $profil) {
         $profilsList[$profil] = Yii::t('common', $profil);
         asort($profilsList);
     }
     if (!Yii::app()->user->isAdmin() && array_merge($profilsList, array("administrator" => Yii::t('common', 'administrator'))) != User::model()->getArrayProfil()) {
         $profilsList['newProfil'] = "Demander un nouveau profil";
     }
     $controler = Yii::app()->getController()->getId();
     $action = Yii::app()->getController()->getAction()->getId();
     $html = CHtml::form(Yii::app()->createUrl("{$controler}/{$action}"), "POST", array('class' => "navbar-form pull-left"));
     $html .= CHtml::dropDownList("activeProfil", Yii::app()->user->getState('activeProfil'), $profilsList, array('id' => "profil", "style" => "width:150px; margin-top: -3px; margin-left: -25px;", "onchange" => "this.form.submit()"));
     $html .= CHtml::endForm();
     return $html;
 }
開發者ID:Biobanques,項目名稱:cbsd_platform,代碼行數:17,代碼來源:GetProfil.php


注:本文中的CHtml::endForm方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。