function outputContinents($dbAdapter)
{
    $gate = new ContinentTableGateway($dbAdapter);
    $result = $gate->findAllSorted();
    foreach ($result as $row) {
        echo '<li class="list-group-item">
			<a href="browse-images.php?=#">' . $row->ContinentName . '</a></li>';
    }
}
function outputContinents($dbAdapter)
{
    $gateContinent = new ContinentTableGateway($dbAdapter);
    $result = $gateContinent->findAllSorted(ContinentName);
    foreach ($result as $row) {
        echo '<option value="' . $row->ContinentCode . '">';
        echo $row->ContinentName;
        echo '</option>';
    }
}
Exemplo n.º 3
0
<?php

include 'dashboard1.php';
require_once 'lib/helpers/visits-setup.inc.php';
$gate = new VisitsTableGateway($dbAdapter);
$result = $gate->findByBrowserPercent();
$result4 = $gate->findAllTables();
$gate2 = new DeviceBrandTableGateway($dbAdapter);
$result2 = $gate2->findByName();
$gate3 = new ContinentTableGateway($dbAdapter);
$result3 = $gate3->findByName();
?>

<!doctype html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="description" content="A front-end template that helps you build fast, modern mobile web apps.">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>Dashboard</title>

    <!-- Add to homescreen for Chrome on Android -->
    <meta name="mobile-web-app-capable" content="yes">
    <link rel="icon" sizes="192x192" href="images/android-desktop.png">

    <!-- Add to homescreen for Safari on iOS -->
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <meta name="apple-mobile-web-app-title" content="Material Design Lite">
    <link rel="apple-touch-icon-precomposed" href="images/ios-desktop.png">
Exemplo n.º 4
0
<?php

include 'partials/header.php';
require_once 'code/lib/helpers/visits-setup.inc.php';
$browserGate = new BrowserTableGateway($dbAdapter);
$visitGate = new VisitTableGateway($dbAdapter);
$continentGate = new ContinentTableGateway($dbAdapter);
$countryGate = new CountryTableGateway($dbAdapter);
$brandGate = new DeviceBrandTableGateway($dbAdapter);
$brandResult = $brandGate->findAllSorted(true);
$browserResult = $browserGate->findAllSorted(true);
$visitsByBrowser = $visitGate->getCountPercentageBy('browser_id');
$visitsByBrand = $visitGate->getCountPercentageBy('device_brand_id');
$continentResult = $continentGate->findAllSorted(true);
$dbAdapter->closeConnection();
?>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.0/jquery.min.js"></script>
<div class="mui-row">
    <div class="mui-col-md-6">
        <div class="mui-panel left top">
		
		<!-- Dashboard Panel 1: Percentage of Visits by Browser -->

		<?php 
echo "<table class='mui-table' id='testtable'><thead><tr><th>Browser</th><th>Percentage of Visits</th></tr></thead><tbody>";
foreach ($visitsByBrowser as $row) {
    $browser = $browserGate->findById($row['browser_id']);
    echo "<tr><td>" . $browser->name . "</td><td>" . $row['percentage'] . "%</td></tr>";
}
echo "</tbody></table>";
?>
function outputContinents($dbAdapter)
{
    $gateContinent = new ContinentTableGateway($dbAdapter);
    $result = $gateContinent->findAllSorted(ContinentName);
    echo json_encode($result);
}