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


PHP foreachRow函数代码示例

本文整理汇总了PHP中foreachRow函数的典型用法代码示例。如果您正苦于以下问题:PHP foreachRow函数的具体用法?PHP foreachRow怎么用?PHP foreachRow使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


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

示例1: parametroGetAll

function parametroGetAll()
{
    $pms = getTable("parametros", "", "");
    $p = array();
    while ($row = foreachRow($pms)) {
        $p[$row['chave']] = $row['valor'];
    }
    return $p;
}
开发者ID:ricain59,项目名称:fortaff,代码行数:9,代码来源:jo_db.php

示例2: modalidadeNaoExistente

function modalidadeNaoExistente($id_delegacao)
{
    $t = getTable('modalidades_nao_existentes', 'id_delegacao = ' . dbInteger($id_delegacao), '');
    $ids = array();
    while ($row = foreachRow($t)) {
        $ids[] = $row['id_modalidade'];
    }
    if (count($ids) == 0) {
        $ids[] = -1;
    }
    return modalidadeGetAll($ids);
}
开发者ID:ricain59,项目名称:fortaff,代码行数:12,代码来源:modalidades.php

示例3: elementoNaoInscritoEmEquipa

function elementoNaoInscritoEmEquipa($id_equipa)
{
    $t = getTable('elementos_equipas_nao_inscritos', 'tipo = \'A\' AND id_equipa = ' . dbInteger($id_equipa), '');
    $ids = array();
    while ($row = foreachRow($t)) {
        $ids[] = $row['id_elemento'];
    }
    if (count($ids) == 0) {
        $ids[] = -1;
    }
    return elementoGetAll($ids);
}
开发者ID:ricain59,项目名称:fortaff,代码行数:12,代码来源:elementosequipas.php

示例4: equipaNaoInscritaEmProva

function equipaNaoInscritaEmProva($id_prova, $id_modalidade, $id_delegacao)
{
    $where = 'equipa_id_modalidade = ' . dbInteger($id_modalidade);
    $where .= ' AND id_prova = ' . dbInteger($id_prova);
    if ($id_delegacao != -1) {
        $where .= ' AND id_delegacao = ' . dbInteger($id_delegacao);
    }
    $t = getTable('provas_classificacoes_equipas_nao_inscritos', $where, '');
    $ids = array();
    while ($row = foreachRow($t)) {
        $ids[] = $row['id_equipa'];
    }
    if (count($ids) == 0) {
        $ids[] = -1;
    }
    return equipaGetAll($ids);
}
开发者ID:ricain59,项目名称:fortaff,代码行数:17,代码来源:provas_classificacoes.php

示例5: em

?>
">
			<td>
				<label for="ipt_Habilitacoes">Habilitações:</label>
			</td>
			<td colspan="3">
				<input type="text" id="ipt_Habilitacoes" name="habilitacoes" value="<?php 
echo $habilitacoes;
?>
" disabled="disabled" />
			</td>
		</tr>
		
		<tr>
			<td>Modalidades:</td>
			<td>
			<!-- pesquisa em (elementos_equipas_total) pelo id_elemento -->
			<?php 
$elemento_modalidades = elementoModalidades($id_elemento);
while ($row = foreachRow($elemento_modalidades)) {
    echo $row['modalidade_nome'] . "</br>";
}
?>
			</td>
		</tr>
	</table>
</form>
<a href="index.php" class="seta-invertida" style="margin-top:10px;">Voltar</a>
<!-- <h1 class="footer_h1"></h1> -->
<?php 
include rootPath('includes/sijo/master_footer.php', 1);
开发者ID:ricain59,项目名称:fortaff,代码行数:31,代码来源:edit.php

示例6: provaGetByFiltro

</h1>
<table id="tableresults" class="tableclass">
	<tr class="rowHeader">
		<th>ID</th>
		<th>Local</th>
		<th>Data</th>
		<th>Modalidade</th>
		<th title="Minutos (min)">Duração</th>
		<th title="Euros (€)">Preço</th>
		<th title="Lotação (Vendidos/Reservados)">Lotação</th>
		<th></th>
	</tr>
<?php 
$alt = true;
$mods = provaGetByFiltro(-1, -1, null, array('X'));
while ($row = foreachRow($mods)) {
    $alt = !$alt;
    ?>
	<tr class="<?php 
    echo $alt ? 'rowalternative' : '';
    ?>
">
		<td><?php 
    echo $row['id_prova'];
    ?>
</td>
		<td title="<?php 
    echo $row['local_descricao'];
    ?>
"><?php 
    echo $row['local_nome'];
开发者ID:ricain59,项目名称:fortaff,代码行数:31,代码来源:index.php

示例7: loginGetAllWithoutAdmin

    <div class="row">
        <div class="col-md-6 col-md-offset-3">
            <form name="changegr" class="form-horizontal" >
                <fieldset>

                    <!-- Form Name -->
                    <legend>Eliminar Funcionário</legend>
                        
                        <div class="form-group">
                        	<label class="col-sm-3 control-label" for="textinput">Funcionário</label>
                        	<div class="col-sm-4 ">
	                            <select id="cbfuncionario" class="form-control">
		                        <option></option>
		                        <?php 
$user = loginGetAllWithoutAdmin();
while ($us = foreachRow($user)) {
    ?>
		                            <option value="<?php 
    echo $us['id'];
    ?>
"><?php 
    echo $us['name'];
    ?>
</option>
		                            <?php 
}
?>
		                    </select>  
		           	</div> 
		           	<div class="col-sm-3">
	                                <input type="button" onclick="delUser()" class="btn btn-primary" value="Desativar">
开发者ID:ricain59,项目名称:fortaff,代码行数:31,代码来源:deluser.php

示例8: massaGetById

function massaGetById($id)
{
    $t = getTable("pp_massa", "pp_massa_id = " . dbInteger($id), "");
    return foreachRow($t);
}
开发者ID:ricain59,项目名称:fortaff,代码行数:5,代码来源:pp_massa.php

示例9: date

<?php

include 'includes/header.php';
?>

<?php 
//dia actual
$date_atual = date('Y-m-d');
$date_mais8 = date("Y-m-d", strtotime($date_atual . ' + 8 days'));
$textmail = '<html><body>';
$table = encomendasGetByFiltro("pp_enc_datedone >= " . dbString($date_atual) . " AND pp_enc_datedone <= " . dbString($date_mais8) . " AND pp_enc_datalevantamento is NULL AND pp_enc_enable = 1", "pp_enc_datedone");
while ($row = foreachRow($table)) {
    $textmail .= '<h2 style="color:blue"> Encomenda Nº ' . $row['pp_enc_id'] . '</h2>';
    $textmail .= '<b>Data do levantamento da encomenda:</b> ' . $row['pp_enc_datedone'] . '<br/>';
    $textmail .= '<b>Nome do cliente:</b> ' . $row['pp_enc_clientname'] . '<br/>';
    $textmail .= '<b>Contacto do cliente:</b> ' . $row['pp_enc_clientcontact'] . '<br/>';
    $textmail .= '<b>Data de criação da encomenda:</b> ' . $row['pp_enc_dateenc'] . '<br/>';
    if ($row['pp_enc_idbolonosso'] == '') {
        $textmail .= '<b>Fez a selecção através de um bolo nosso:</b> Não<br/>';
    } else {
        $textmail .= '<b>Fez a selecção através de um bolo nosso:</b> Sim<br/>';
        $bolonosso = boloGetById($row['pp_enc_idbolonosso']);
        //mail
        $textmail .= '<img height="150" width="250" src="' . $bolonosso['pp_bolo_urlimage'] . '"/><br/>';
    }
    $textmail .= '<h4 style="color:green">Composição:</h4>';
    if ($row['pp_enc_coberturaid'] == '') {
        $textmail .= '<b>Cobertura:</b> ' . $row['pp_enc_coberturaoutra'] . '<br/>';
    } else {
        $data_cob = coberturaGetById($row['pp_enc_coberturaid']);
        $textmail .= '<b>Cobertura:</b> ' . $data_cob['pp_cobertura_designacao'] . '<br/>';
开发者ID:ricain59,项目名称:fortaff,代码行数:31,代码来源:view_encdiario.php

示例10: reparadorGetById

function reparadorGetById($id)
{
    $t = getTable("reparador", "rep_id = {$id}", "");
    return foreachRow($t);
}
开发者ID:ricain59,项目名称:fortaff,代码行数:5,代码来源:dbreparador.php

示例11: modifBolosGetById

function modifBolosGetById($id)
{
    $t = getTable("pp_modif_bolos", "pp_modif_id = " . dbInteger($id), "");
    return foreachRow($t);
}
开发者ID:ricain59,项目名称:fortaff,代码行数:5,代码来源:pp_modif_bolos.php

示例12: switch

        break;
    case "delegacoes":
        switch ($output) {
            case "xml":
                $xml = '<?xml version="1.0" encoding="ISO-8859-1" ?>';
                $xml .= '<countries>';
                $delegacoes = delegacaoGetByFiltro(-1, null, array('X'));
                while ($country = foreachRow($delegacoes)) {
                    $xml .= '<country>';
                    $xml .= '<id>' . $country['id_pais'] . '</id>';
                    $xml .= '<name>' . $country['pais_nome'] . '</name>';
                    $xml .= '<responsible>' . $country['nome_responsavel'] . '</responsible>';
                    $xml .= '<average_age>' . $country['media_idade'] . '</average_age>';
                    $xml .= '<medals_gold>' . $country['ouro'] . '</medals_gold>';
                    $xml .= '<medals_silver>' . $country['prata'] . '</medals_silver>';
                    $xml .= '<medals_bronze>' . $country['bronze'] . '</medals_bronze>';
                    $xml .= '</country>';
                }
                $xml .= '</countries>';
                echo $xml;
                break;
            case "json":
                $delegacoes = delegacaoGetByFiltro(-1, null, array('X'));
                while ($a = foreachRow($delegacoes)) {
                    $x[] = array('id_delegacao' => $a['id_delegacao'], 'id_pais' => $a['id_pais'], 'pais_nome' => utf8_encode($a['pais_nome']), 'nome_responsavel' => utf8_encode($a['nome_responsavel']), 'media_idade' => $a['media_idade'], 'ouro' => $a['ouro'], 'prata' => $a['prata'], 'bronze' => $a['bronze']);
                }
                echo ujson_encode($x);
                break;
        }
}
closeDataBase();
开发者ID:ricain59,项目名称:fortaff,代码行数:31,代码来源:data.php

示例13: alpha

        <!-- Loading Screen -->
        
        <div u="loading" style="position: absolute; top: 0px; left: 0px;">
            <div style="filter: alpha(opacity=70); opacity:0.7; position: absolute; display: block;
                background-color: #000000; top: 0px; left: 0px;width: 100%;height:100%;">
            </div>
            <div style="position: absolute; display: block; background: url(images/loading2.gif) no-repeat center center;
                top: 0px; left: 0px;width: 100%;height:100%;">
            </div>
        </div>

        <!-- Slides Container -->
        <div u="slides" style="cursor: move; position: absolute; left: 0px; top: 0px; width: 800px; height: 550px; overflow: hidden;">
        	
        	<?php 
    while ($bolo = foreachRow($table)) {
        ?>
                    <div><img u="image" src="<?php 
        echo $bolo['pp_bolo_urlimage'];
        ?>
"/></div>
                    <?php 
    }
    ?>
        	
        </div>
        
        <!--#region Bullet Navigator Skin Begin -->
        <!-- Help: http://www.jssor.com/development/slider-with-bullet-navigator-jquery.html -->
        <style>
            /* jssor slider bullet navigator skin 05 css */
开发者ID:ricain59,项目名称:fortaff,代码行数:31,代码来源:index.php

示例14: gregGetLastNumberGr

function gregGetLastNumberGr($year)
{
    $t = getNumberGr("grep", "gr_number LIKE '%" . $year . "-%'", "gr_number", "1", "gr_number", "DESC");
    return foreachRow($t);
}
开发者ID:ricain59,项目名称:fortaff,代码行数:5,代码来源:dbgrep.php

示例15: coberturaGetById

function coberturaGetById($id)
{
    $t = getTable("pp_cobertura", "pp_cobertura_id = " . dbInteger($id), "");
    return foreachRow($t);
}
开发者ID:ricain59,项目名称:fortaff,代码行数:5,代码来源:pp_cobertura.php


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