From 3e3e9986975095df4660e62ab6e7bc15af4c8970 Mon Sep 17 00:00:00 2001
From: Brandon Rodriguez <brodriguez8774@gmail.com>
Date: Thu, 27 Oct 2016 12:25:53 -0400
Subject: [PATCH] Mostly done ch11pr02

Just needs final implementation of filtering, I believe?
Commiting just in case I explode everything.
---
 chapter11/project2/browse-images.php | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)

diff --git a/chapter11/project2/browse-images.php b/chapter11/project2/browse-images.php
index 293a046..ba0d8e0 100644
--- a/chapter11/project2/browse-images.php
+++ b/chapter11/project2/browse-images.php
@@ -56,7 +56,7 @@
   $sqlCitiesMatch = $pdo->query($sql);
 
 
-  if ($_SERVER['REQUEST_METHOD'] == 'GET') {
+  /*if ($_SERVER['REQUEST_METHOD'] == 'GET') {
     echo "<br>";
     if ( isset($_GET['city']) ) {
       echo $_GET['city'];
@@ -66,7 +66,7 @@
       echo $_GET['country'];
     }
     echo "<br>";
-  }
+  }*/
 
   
   # Returns filtered City/Country.
@@ -127,7 +127,6 @@
       WHERE GeoCountries.ISO = TravelImageDetails.CountryCodeISO AND
       GeoCities.GeoNameID = TravelImageDetails.CityCode AND
       TravelImage.ImageID = TravelImageDetails.ImageID;";
-      echo $sql;
   $sqlFilterMatch = $pdo->query($sql);
 
 ?>
@@ -196,9 +195,9 @@
                   #GetDBFilterMatch();
                   if ($sqlFilterMatch) {
                       while ($row = $sqlFilterMatch->fetch()) {
-                        echo "<figure style='display: inline-block; padding-left: 1%; padding-right: 1%; width=150px;'>";
-                        echo "<a href='" . $row['ImageID'] . "'><img src='images/travel/" . $row['Path'] . "'></a>";
-                        echo "<figcaption style='max-width: 150px;'>" . $row['Title'] . "</figcaption>";
+                        echo "<figure style='display: inline-block; padding: 1%; width=150px; background-color: #fff; margin: 15px;'>";
+                        echo "<a href='" . $row['ImageID'] . "'><img src='images/travel/square/" . $row['Path'] . "'></a>";
+                        echo "<figcaption style='max-width: 150px; text-align: center; font-size: 0.75em;'>" . $row['Title'] . "</figcaption>";
                         echo "</figure>";
                       }
                     } else {
-- 
GitLab