本文整理汇总了PHP中XUtils::selected方法的典型用法代码示例。如果您正苦于以下问题:PHP XUtils::selected方法的具体用法?PHP XUtils::selected怎么用?PHP XUtils::selected使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类XUtils
的用法示例。
在下文中一共展示了XUtils::selected方法的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: array
" class="actionBtn"><span>录入</span></a></li>
</ul>
<div class="search right">
<?php
$form = $this->beginWidget('CActiveForm', array('id' => 'searchForm', 'method' => 'get', 'htmlOptions' => array('name' => 'xform')));
?>
<select name="groupId" id="groupId">
<option value="">=组=</option>
<?php
foreach ((array) $this->group_list as $group) {
?>
<option value="<?php
echo $group['id'];
?>
" <?php
XUtils::selected($group['id'], $model->group_id);
?>
><?php
echo $group['group_name'];
?>
</option>
<?php
}
?>
</select>
<select name="sex" id="sex">
<option value="">性别</option>
<option value="男">男</option>
<option value="女">女</option>
</select>
用户名
示例2: foreach
case 'radio':
?>
<?php
foreach (explode('|', $row['data_default']) as $v) {
?>
<?php
$val = @explode('=', $v);
?>
<input name="attr[<?php
echo $key;
?>
][val]" type="radio" value="<?php
echo $val[1];
?>
" <?php
XUtils::selected($val[1], CHtml::encode($attrData['_' . $row['attr_name_alias']]), 'checked');
?>
/>
<?php
echo $val[0];
?>
<?php
}
?>
<?php
}
?>
<br />
标识:_<?php
echo CHtml::encode($row['attr_name_alias']);
?>
示例3: foreach
</tr>
<tr>
<td class="tb_title">城市:</td>
</tr>
<tr >
<td >
<select name="Subject[city_id]" id="Subject_city_id" class="validate[required]">
<option value>==所有城市==</option>
<?php
foreach ((array) $this->city_list as $city) {
?>
<option value="<?php
echo $city['id'];
?>
" <?php
XUtils::selected($city['id'], $model->city_id);
?>
><?php
echo $city['name'];
?>
</option>
<?php
}
?>
</select>
</td>
</tr>
<tr>
<td class="tb_title">项目时间:</td>
</tr>
<tr>
示例4: foreach
</option>
<?php
}
?>
</select> -->
物业类型
<select name="propertyType_id" id="propertyType_id">
<option value="">=所有类型=</option>
<?php
foreach ((array) $this->propertyType_list as $propertyType) {
?>
<option value="<?php
echo $propertyType['id'];
?>
" <?php
XUtils::selected($propertyType['id'], $model->propertyType_id);
?>
><?php
echo $propertyType['name'];
?>
</option>
<?php
}
?>
</select>
房源编号/地址
<input id="h_name" type="text" name="h_name" value="" class="txt" size="50"/>
<input type="checkbox" id="is_recommend" name="is_recommend" value="1"/>是否推荐
<input name="searchsubmit" type="submit" value="查询" class="button "/>
<script type="text/javascript">
$(function(){
示例5:
echo XUtils::selected($config['admin_logger'], 'close');
?>
>关闭</option>
</select></td>
</tr>
<tr>
<td class="tb_title">站点开关/关闭说明:</td>
</tr>
<tr >
<td ><select name="Config[site_status]">
<option value="open" <?php
echo XUtils::selected($config['site_status'], 'open');
?>
>开启</option>
<option value="close" <?php
echo XUtils::selected($config['site_status'], 'close');
?>
>关闭</option>
</select></td>
</tr>
<tr >
<td ><textarea name="Config[site_status_intro]" class="tarea" ><?php
echo $config['site_status_intro'];
?>
</textarea></td>
</tr>
<tr>
<td class="tb_title">管理员邮箱:</td>
</tr>
<tr >
<td ><input type="text" class="txt" name="Config[admin_email]" value="<?php
示例6:
<td class="tb_title">不允许注册用户名:</td>
</tr>
<tr >
<td ><input type="text" class="txt w400" name="Config[user_name_disable]" value="<?php
echo $config['user_name_disable'];
?>
" /></td>
</tr>
<tr>
<td class="tb_title">会员审核:</td>
</tr>
<tr >
<td ><select name="Config[user_verify]">
<option value="open" <?php
echo XUtils::selected($config['user_verify'], 'open');
?>
>审核后才能登录</option>
<option value="close" <?php
echo XUtils::selected($config['user_verify'], 'close');
?>
>不需要审核</option>
</select></td>
</tr>
<tr class="submit">
<td ><input type="submit" name="editsubmit" value="提交" class="button" tabindex="3" /></td>
</tr>
</table>
</form>
<?php
echo $this->renderPartial('/_include/footer');
示例7: foreach
if ($model->scope != 'post') {
?>
style="display:none"<?php
}
?>
> 栏目归属:
<select name="Attr[catalog_id]" >
<option value="0">==选择栏目==</option>
<?php
foreach ((array) Catalog::get(0, $this->_catalog) as $catalog) {
?>
<option value="<?php
echo $catalog['id'];
?>
" <?php
XUtils::selected($catalog['id'], $model->catalog_id);
?>
><?php
echo $catalog['str_repeat'];
echo $catalog['catalog_name'];
?>
</option>
<?php
}
?>
</select>
</span></td>
</tr>
<tr>
<td class="tb_title">属性类型</td>
</tr>
示例8:
?>
>右下</option>
<option value="3" <?php
echo XUtils::selected($config['upload_water_position'], '3');
?>
>右上</option>
<option value="1" <?php
echo XUtils::selected($config['upload_water_position'], '1');
?>
>左上</option>
<option value="2" <?php
echo XUtils::selected($config['upload_water_position'], '2');
?>
>左下</option>
<option value="4" <?php
echo XUtils::selected($config['upload_water_position'], '4');
?>
>中间</option>
</select>
</td>
</tr>
<tr>
<td class="tb_title">水印边距 upload_water_padding / upload_water_padding:</td>
</tr>
<tr >
<td ><input type="text" class="txt w100" name="Config[upload_water_padding]" value="<?php
echo $config['upload_water_padding'];
?>
" datatype="Require" msg="必须填写"/>像素(px)<span info="Config[upload_water_padding]"></span></td>
示例9: array
</ul>
<div class="search right">
<?php
$form = $this->beginWidget('CActiveForm', array('id' => 'searchForm', 'method' => 'get', 'action' => array('index'), 'htmlOptions' => array('name' => 'xform', 'class' => 'right ')));
?>
房源
<select name="house_id" id="house_id">
<option value="">=所有房源=</option>
<?php
foreach ((array) $this->house_list as $house) {
?>
<option value="<?php
echo $house['id'];
?>
" <?php
XUtils::selected($house['id'], $model->house_id);
?>
><?php
echo $house['name'];
?>
</option>
<?php
}
?>
</select>
<input name="searchsubmit" type="submit" value="查询" class="button "/>
<script type="text/javascript">
$(function(){
$("#xform").validationEngine();
});
</script>
示例10:
" />
<span info="Config[sender]"></span></td>
</tr>
<tr>
<td class="tb_title">是否需要验证:</td>
</tr>
<tr >
<td ><label>
<input type="radio" class="radio" name="Config[smtp_auth]" value="1" onclick="showObj('mail_smtp_auth');" <?php
echo XUtils::selected($config['smtp_auth'], 1, 'checked');
?>
/>
是</label>
<label>
<input type="radio" class="radio" name="Config[smtp_auth]" value="0" onclick="hideObj('mail_smtp_auth');" <?php
echo XUtils::selected($config['smtp_auth'], 0, 'checked');
?>
/>
否</label></td>
</tr>
<tbody id="mail_smtp_auth" >
<tr>
<td class="tb_title">SMTP 身份验证用户名:</td>
</tr>
<tr >
<td ><input type="text" class="txt" name="Config[smtp_user]" value="<?php
echo $config['smtp_user'];
?>
"/></td>
</tr>
<tr>
示例11: foreach
</td>
</tr>
<tr>
<td class="tb_title">所属分类:</td>
</tr>
<tr >
<td ><select name="Catalog[parent_id]" id="Catalog_parent_id">
<option value="0">==顶级分类==</option>
<?php
foreach ((array) Catalog::get(0, $this->_catalog) as $catalog) {
?>
<option value="<?php
echo $catalog['id'];
?>
" <?php
XUtils::selected($catalog['id'], $model->parent_id);
?>
><?php
echo $catalog['str_repeat'];
echo $catalog['catalog_name'];
?>
</option>
<?php
}
?>
</select></td>
</tr>
<tr>
<td class="tb_title">显示方式:</td>
</tr>
<tr >
示例12: foreach
?>
</option>
<?php
}
?>
</select>
<select name="Post[special_id]">
<option value="0">==所属专题==</option>
<?php
foreach ((array) Bagecms::getList('Special', '_special') as $speical) {
?>
<option value="<?php
echo $speical['id'];
?>
" <?php
XUtils::selected($speical['id'], $model->special_id);
?>
><?php
echo $speical['title'];
?>
</option>
<?php
}
?>
</select></td>
</tr>
<tr>
<td class="tb_title">来源:</td>
</tr>
<tr >
<td ><?php
示例13: array
<td ><?php
echo $form->textField($model, 'qq', array('size' => 30, 'maxlength' => 128));
?>
</td>
</tr>
<tr>
<td class="tb_title">sex:</td>
</tr>
<tr >
<td class="tb_title"><input type="radio" name="User[sex]" id="radio" value="男" <?php
XUtils::selected('男', $model->sex, 'checked');
?>
/>
男
<input type="radio" name="User[sex]" id="radio" value="女" <?php
XUtils::selected('女', $model->sex, 'checked');
?>
/>
女 </td>
</tr>
<tr>
<td class="tb_title">工作单位:</td>
</tr>
<tr >
<td ><?php
echo $form->textField($model, 'work_company', array('size' => 30, 'maxlength' => 128));
?>
</td>
</tr>
<tr>
<td class="tb_title">地区:</td>