Пример #1
0
 public function getResultTable($posting, $location = null)
 {
     try {
         echo '<table class="resultheader" id="classifieds" cellspacing=0>';
         echo '<tr>';
         echo '<th class="cuisine">';
         echo 'Category';
         echo '</th>';
         echo '<th class="location">';
         echo 'Suburb';
         echo '</th>';
         echo '<th class="title">';
         echo 'Title';
         echo '</th>';
         echo '<th class="photo">';
         echo 'Photo';
         echo '</th>';
         echo '<th class="price">';
         echo 'Price <br />(' . $location->getCurrencyAndSymbol() . ')';
         echo '</th>';
         echo '</tr>';
         foreach ($posting as $key => $value) {
             echo '<tr class="postingrow">';
             echo $this->getPostingInfoLinkHtml($value->cat2name, $value->postingid);
             echo $this->getPostingInfoLinkHtml($value->suburb, $value->postingid);
             echo $this->getPostingInfoLinkHtml($value->title, $value->postingid);
             if (Pstposting::photoExists($value->photo)) {
                 $tmpBool = "Yes";
             } else {
                 $tmpBool = "No";
             }
             echo $this->getPostingInfoLinkHtml($tmpBool, $value->postingid);
             echo $this->getPostingInfoLinkHtml($value->priceDisplay, $value->postingid);
             echo '</tr>';
         }
         echo '</table>';
     } catch (Exception $e) {
         logError('get results for classifieds', $e);
         echo $e;
     }
     return parent::getResultTable($posting);
 }