当前位置: 首页>>代码示例>>PHP>>正文


PHP Widgets::multipleFields方法代码示例

本文整理汇总了PHP中Widgets::multipleFields方法的典型用法代码示例。如果您正苦于以下问题:PHP Widgets::multipleFields方法的具体用法?PHP Widgets::multipleFields怎么用?PHP Widgets::multipleFields使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Widgets的用法示例。


在下文中一共展示了Widgets::multipleFields方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: array

<?php 
if (isset($_GET['id'])) {
    if (!($data = Yii::app()->functions->getAddonCategory2($_GET['id']))) {
        echo "<div class=\"uk-alert uk-alert-danger\">" . Yii::t("default", "Sorry but we cannot find what your are looking for.") . "</div>";
        return;
    }
}
?>
                                 
<?php 
if (Yii::app()->functions->multipleField() == 2) {
    ?>

<?php 
    Widgets::multipleFields(array('AddOn Name', 'Description'), array('subcategory_name', 'subcategory_description'), $data, array(true, false));
    ?>
<div class="spacer"></div>

<?php 
} else {
    ?>
<div class="uk-form-row">
  <label class="uk-form-label"><?php 
    echo Yii::t("default", "AddOn Name");
    ?>
</label>
  <?php 
    echo CHtml::textField('subcategory_name', isset($data['subcategory_name']) ? $data['subcategory_name'] : "", array('class' => 'uk-form-width-large', 'data-validation' => "required"));
    ?>
</div>
开发者ID:ashishvazirani,项目名称:food,代码行数:30,代码来源:addon_category_add.php

示例2: isset

        return;
    }
}
Yii::app()->functions->data = 'list';
$subcat = Yii::app()->functions->getSubcategory();
$selected_cat = isset($data['category']) ? json_decode($data['category']) : false;
?>
                                 

<div class="uk-grid">

<div class="uk-width-1-2">

<?php 
if (Yii::app()->functions->multipleField() == 2) {
    Widgets::multipleFields(array('AddOn Item', 'Description'), array('sub_item_name', 'item_description'), $data, array(true, false));
    ?>
<div class="spacer"></div>

<?php 
} else {
    ?>
<div class="uk-form-row">
  <label class="uk-form-label"><?php 
    echo Yii::t("default", "AddOn Item");
    ?>
</label>
  <?php 
    echo CHtml::textField('sub_item_name', isset($data['sub_item_name']) ? $data['sub_item_name'] : "", array('class' => 'uk-form-width-large', 'data-validation' => "required"));
    ?>
</div>
开发者ID:ashishvazirani,项目名称:food,代码行数:31,代码来源:addon_item_new.php

示例3: array

<?php 
if (isset($_GET['id'])) {
    if (!($data = Yii::app()->functions->getSize($_GET['id']))) {
        echo "<div class=\"uk-alert uk-alert-danger\">" . Yii::t("default", "Sorry but we cannot find what your are looking for.") . "</div>";
        return;
    }
}
?>
                                 

<?php 
if (Yii::app()->functions->multipleField() == 2) {
    ?>

<?php 
    Widgets::multipleFields(array('Size Name'), array('size_name'), $data, array(true));
    ?>
<div class="spacer"></div>

<?php 
} else {
    ?>

<div class="uk-form-row">
  <label class="uk-form-label"><?php 
    echo Yii::t("default", "Size Name");
    ?>
</label>
  <?php 
    echo CHtml::textField('size_name', isset($data['size_name']) ? $data['size_name'] : "", array('class' => 'uk-form-width-large', 'data-validation' => "required"));
    ?>
开发者ID:ashishvazirani,项目名称:food,代码行数:31,代码来源:size_add.php

示例4: isset

    //dump($two_flavors_position);
    $require_addon = isset($data['require_addon']) ? (array) json_decode($data['require_addon']) : false;
}
?>
                                 


<div class="uk-grid">
    <div class="uk-width-1-2">
    
    <?php 
if (Yii::app()->functions->multipleField() == 2) {
    ?>
    
    <?php 
    Widgets::multipleFields(array('Food Item Name', 'Description'), array('item_name', 'item_description'), $data, array(true, false), array('text', 'textarea'));
    ?>
	<div class="spacer"></div>

    <?php 
} else {
    ?>
	<div class="uk-form-row">
	<label class="uk-form-label"><?php 
    echo Yii::t("default", "Food Item Name");
    ?>
</label>
	<?php 
    echo CHtml::textField('item_name', isset($data['item_name']) ? $data['item_name'] : "", array('class' => 'uk-form-width-large', 'data-validation' => "required"));
    ?>
	</div>
开发者ID:ashishvazirani,项目名称:food,代码行数:31,代码来源:food-item-add.php

示例5: array

    echo CHtml::hiddenField("redirect", Yii::app()->request->baseUrl . "/merchant/CookingRef/Do/Add");
}
?>

<?php 
if (isset($_GET['id'])) {
    if (!($data = Yii::app()->functions->getCookingRef($_GET['id']))) {
        echo "<div class=\"uk-alert uk-alert-danger\">" . Yii::t("default", "Sorry but we cannot find what your are looking for.") . "</div>";
        return;
    }
}
?>
                                 
<?php 
if (Yii::app()->functions->multipleField() == 2) {
    Widgets::multipleFields(array('Cooking Ref. name'), array('cooking_name'), $data, array(true));
    ?>
<div class="spacer"></div>
<?php 
} else {
    ?>
<div class="uk-form-row">
  <label class="uk-form-label"><?php 
    echo Yii::t("default", "Cooking Ref. name");
    ?>
</label>
  <?php 
    echo CHtml::textField('cooking_name', isset($data['cooking_name']) ? $data['cooking_name'] : "", array('class' => 'uk-form-width-large', 'data-validation' => "required"));
    ?>
</div>
<?php 
开发者ID:ashishvazirani,项目名称:food,代码行数:31,代码来源:cooking-ref-add.php

示例6: array

    echo CHtml::hiddenField("redirect", Yii::app()->request->baseUrl . "/merchant/ingredients/Do/Add");
}
?>

<?php 
if (isset($_GET['id'])) {
    if (!($data = Yii::app()->functions->getIngredients($_GET['id']))) {
        echo "<div class=\"uk-alert uk-alert-danger\">" . Yii::t("default", "Sorry but we cannot find what your are looking for.") . "</div>";
        return;
    }
}
?>
                                 
<?php 
if (Yii::app()->functions->multipleField() == 2) {
    Widgets::multipleFields(array('ingredients name'), array('ingredients_name'), $data, array(true));
    ?>
<div class="spacer"></div>

<?php 
} else {
    ?>

<div class="uk-form-row">
  <label class="uk-form-label"><?php 
    echo Yii::t("default", "ingredients name");
    ?>
</label>
  <?php 
    echo CHtml::textField('ingredients_name', isset($data['ingredients_name']) ? $data['ingredients_name'] : "", array('class' => 'uk-form-width-large', 'data-validation' => "required"));
    ?>
开发者ID:ashishvazirani,项目名称:food,代码行数:31,代码来源:ingredients-add.php


注:本文中的Widgets::multipleFields方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。