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


PHP Requirements::find_by_sql方法代码示例

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


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

示例1: customEncrypt

<?php

require_once "inc/initialize.php";
?>

 <?php 
$sql = "SELECT * FROM requirements ORDER BY `id` DESC ";
$require_contents = Requirements::find_by_sql($sql);
?>
     <ul>
     <?php 
foreach ($require_contents as $require_content) {
    ?>
 
     
    <li>
        <a href='programs_details.php?id=<?php 
    echo customEncrypt($require_content->id);
    ?>
'>
    <i class="icon-hand-right"></i> <?php 
    echo htmlentities($require_content->name);
    ?>
        </a>
    </li>
    <?php 
}
?>
    
    </ul>
开发者ID:Ghaji,项目名称:form_application,代码行数:30,代码来源:requrement_details.php

示例2: include_layout_template

		<br>
		<br>

		<!-- Content -->
		<div class="row-fluid">

			<?php 
include_layout_template('admin_menu.php');
?>

			<div class="span9">
				<h2>Program Requirements</h2>
				<hr>
						<?php 
$query = "SELECT * FROM Requirements ORDER BY id DESC";
$result = Requirements::find_by_sql($query);
$pagecounter = 1;
$serialno = 1;
$max = 10;
$number_of_requirements = sizeof($result);
echo '<div class="tabbable">
								<div class="tab-content">';
foreach ($result as $row) {
    if ($serialno % $max == 1) {
        if ($pagecounter == 1) {
            echo '<div class="tab-pane active" id="' . $pagecounter . '">';
        } else {
            echo '<div class="tab-pane" id="' . $pagecounter . '">';
        }
        echo '<table class="table table-hover">
									<thead>
开发者ID:Ghaji,项目名称:form_application,代码行数:31,代码来源:view_admission_requirements.php

示例3:

    ?>
                           		Date: <i class="icon-calendar"></i> <?php 
    echo $item->created_time;
    ?>
                          </div> 
                          <hr> 
                    </p>
                   
                <?php 
}
?>
        		<h3><i class="icon-certificate"></i> Admission Requirements</h3>
            <ul>
             <?php 
$query1 = "SELECT * FROM requirements\r\n            WHERE visible = 1\r\n            AND name !='' \r\n            ORDER BY id DESC \r\n            Limit 3";
$requirements = Requirements::find_by_sql($query1);
foreach ($requirements as $prog) {
    if ($prog->name != '') {
        ?>
                    <li>
                   
                   <a href='#?id=<?php 
        echo $prog->id;
        ?>
'><?php 
        echo $prog->name;
        ?>
</a> 
                    </li>
                
                <?php 
开发者ID:Ghaji,项目名称:form_application,代码行数:31,代码来源:index3.php


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