Exemplo n.º 1
0
    <head>
        <meta charset="UTF-8">
        <!-- Latest compiled and minified CSS -->
        <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css">

        <!-- Optional theme -->
        <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap-theme.min.css">
        <title>View Site Database</title>
    </head>
    <body>
        <?php 
//Includes HEader template
include './includes/header.php';
//Includes database utilities
include_once './includes/dbUtil.php';
$columns = colName();
//Checks if Post Request to assign the "$site_id" variable.
if (isPostRequest()) {
    $site_id = filter_input(INPUT_POST, 'site_id');
    $links = dbSite($site_id);
} else {
    $site_id = null;
}
include_once "./includes/form.php";
//Includes the Results Table if $links is set.
if (isset($links)) {
    include_once "./includes/resultsTable.php";
}
?>

Exemplo n.º 2
0
            </select>
                <input type="submit" value="Sort"/>
            </form>
        </td>
        <td>
            <form method="POST" action="#">
                Enter Name:
                <input type="text" value="<?php 
if (isset($searchq)) {
    echo $searchq;
}
?>
" name="searchq"/>
                <select name="col">
            <?php 
$cols = colName();
foreach ($cols as $col) {
    if ($col != "user_id" && $col != "address_group_id" && $col != "address_id" && $col != "image") {
        ?>
                <option 
                    <?php 
        if (!empty($selectedCol) && $selectedCol == $col) {
            ?>
                    selected="selected"
                    <?php 
        }
        ?>
                    value="<?php 
        echo $col;
        ?>
">
Exemplo n.º 3
0
<?php

$order = "";
$column = "";
$colName = colName("corps");
if (isGetRequest()) {
    $order = filter_input(INPUT_GET, 'order');
    $column = filter_input(INPUT_GET, 'columnSort');
}
?>


<form action="#" method="GET">
    <table>
        <tr>
            <td>
                Ascending 
            </td>
            <td>
                <input type="radio" name="order" <?php 
if ($order === 'ASC') {
    ?>
checked="checked" <?php 
}
?>
value="ASC"/>
            </td>
        </tr>
        <tr>
            <td>
                Descending