includes/searcher.php
/**
   * Plant Table Renderer
   *
   * Queries the database for all possible data related to any data coming from
   * Symbiota in a mirror-based `plants` table.
   *
   * @return String
   */
Plant Table Renderer
Queries the database for all possible data related to any data coming from
Symbiota in a mirror-based `plants` table.

@return String
Plant Table Renderer Queries the database for all possible data related to any data coming from Symbiota in a mirror - based ` plants ` table . @return String
private function renderTablePlants() {
    global $application;
    $html = "";
    $prepare = $this->connection->prepare("
      SELECT id, scientific_name, habitat
      FROM   plants
      WHERE  (" . $this->renderQuery("plants") . ")
        AND  scientific_name != ''
    ");
    $prepare->execute($this->populateArray("plants"));
    foreach ($prepare->fetchAll() as $current=>$result) {
      $html .= "<tr>";
      $html .= "<td>"
        . "<a href=\"" . $application->getURL() . "view-plant.php?id=" . $result["id"] . "\">"
        . "<img src=\"#\" class=\"img-responsive\" alt=\"Thumbnail of " . $result["scientific_name"] . "\">"
        . "</a>"
        . "</td>";
      $html .= "<td>"
        . "<a href=\"" . $application->getURL() . "view-plant.php?id=" . $result["id"] . "\">" . $result["scientific_name"] . "</a>"
        . "</td>";
      $html .= "<td>" . $result["habitat"] . "</td>";
      $html .= "</tr>";
    }
    return $html;
  }
private function renderTablePlants ( ) { global $ application ; $ html = " " ; $ prepare = $ this -> connection -> prepare ( " 
      SELECT id, scientific_name, habitat
      FROM   plants
      WHERE  ( " . $ this -> renderQuery ( " plants " ) . " )
        AND  scientific_name != ''
     " ) ; $ prepare -> execute ( $ this -> populateArray ( " plants " ) ) ; foreach ( $ prepare -> fetchAll ( ) as $ current => $ result ) { $ html .= " <tr> " ; $ html .= " <td> " . " <a href= \" " . $ application -> getURL ( ) . " view-plant.php?id= " . $ result [ " id " ] . " \" > " . " <img src= \" # \"  class= \" img-responsive \"  alt= \" Thumbnail of  " . $ result [ " scientific_name " ] . " \" > " . " </a> " . " </td> " ; $ html .= " <td> " . " <a href= \" " . $ application -> getURL ( ) . " view-plant.php?id= " . $ result [ " id " ] . " \" > " . $ result [ " scientific_name " ] . " </a> " . " </td> " ; $ html .= " <td> " . $ result [ " habitat " ] . " </td> " ; $ html .= " </tr> " ; } return $ html ; }
Plant Table Renderer
 Queries the database for all possible data related to any data coming from
 Symbiota in a mirror-based `plants` table.
Plant Table Renderer Queries the database for all possible data related to any data coming from Symbiota in a mirror - based ` plants ` table .
// Render the thumbnail with a link. // TODO: Retrieve Symbiota thumbnail URL once its ready. // Render the scientific name with a link. // Render the habitat plainly.