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


PHP FormHelper::array2options方法代码示例

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


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

示例1:

<p>
    <label>State:</label>
    <span>
        <select name="fldState">
            <option value="" class="selectgrey">Any State</option>
            <?php 
echo FormHelper::array2options($stateList, $fldState);
?>
        </select>
    </span>
</p>

<!-- ZIP code and Distance -->
<p class="alt">
    <label>ZIP Code:</label>
    <span>
        <input type="text" name="fldZipCode" style="width:80px;margin-right:3px;"
               value="<?php 
echo $fldZipCode;
?>
" />
        within
        <select name="fldDistance" style="width: 95px;margin-right:5px;">
            <option value="any">Any Miles</option>  
            <?php 
echo FormHelper::array2options($distanceList, $fldDistance);
?>
        </select>										
    </span>
</p>
开发者ID:trungjc,项目名称:collegeprospectnetwork,代码行数:30,代码来源:athleteSearch_Location.php

示例2:

<!-- Positions -->
<?php 
if (count($sportList) == 1) {
    ?>
    <p class="alt">
<?php 
} else {
    ?>
    <p>
<?php 
}
?>
    <label>Sport Position:</label>
    <span>
        <select name="fldPrimaryPosition">
            <option value="" class="selectgrey">Any Primary Position</option>
            <?php 
echo FormHelper::array2options($positionList, $fldPrimaryPosition);
?>
        </select>
    </span>
    <span style="padding-top:3px;">
        <select name="fldSecondaryPosition">
            <option value="" class="selectgrey">Any Secondary Position</option>
            <?php 
echo FormHelper::array2options($positionList, $fldSecondaryPosition);
?>
        </select>
    </span>
</p>
开发者ID:trungjc,项目名称:collegeprospectnetwork,代码行数:30,代码来源:athleteSearch_AthStatsLeft.php

示例3:

?>
        </select>
    </span>
</p>

<!-- Class Rank -->
<p>
    <label>Class Rank:</label>
    <span>
        <select name="fldClassRank">
            <option value="" class="selectgrey">Any Class Rank</option>
            <?php 
echo FormHelper::array2options($classRankList, $fldClassRank);
?>
        </select>
    </span>
</p>

<!-- Intended Major -->
<p class="alt">
    <label>Intended Major:</label>
    <span>
        <select name="fldIntendedMajor">
            <option value="" class="selectgrey">Any Intended Major</option>
            <?php 
echo FormHelper::array2options($majorList, $fldIntendedMajor);
?>
        </select>
    </span>
</p>
开发者ID:trungjc,项目名称:collegeprospectnetwork,代码行数:30,代码来源:athleteSearch_AcadStats.php

示例4:

                </div>

                <div class="col-right">

                  <p>

                    <label>Ratings:</label>

                    <span style="padding-top:3px;">

                    <select name="fldIntangible_rating_min">

                      <option value="" class="selectgrey">Any Rating</option>

                      <?php 
echo FormHelper::array2options($ratingList, $fldIntangible_rating_min);
?>


                    </select>

                    </span>

                    <?php 
/*?><label>&nbsp;</label>

							<span style="padding-top:3px;">

								<select name="fldIntangible_rating_max">

									<option value="" class="selectgrey">Any Max Rating</option>
开发者ID:trungjc,项目名称:collegeprospectnetwork,代码行数:31,代码来源:athleteSearch_all.php


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