Advertisement
Greenice

Zend Framework View Example

Jan 31st, 2019
337
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.47 KB | None | 0 0
  1. <?php
  2.     $tabAccordionHelper = $this->getHelper('TabsAccordion');
  3.     $this->itemsStart = $this->isMobile == true ? $tabAccordionHelper->startAccordion('business-tabs') : $tabAccordionHelper->startTab('business-tabs');
  4.     $this->itemsEnd = $this->isMobile == true ? $tabAccordionHelper->endAccordion() : $tabAccordionHelper->endTab();
  5.  
  6.     echo $this->itemsStart;
  7.     echo $this->render('business-page/tabs/ratings-reputation.phtml');
  8.     echo $this->render('business-page/tabs/profile.phtml');
  9.     echo $this->render('business-page/tabs/media.phtml');
  10.     echo $this->render('business-page/tabs/rate-business.phtml');
  11.     echo $this->itemsEnd;
  12. ?>
  13.  
  14. <script>
  15. <?php
  16.     if ($this->showMap)
  17.     {
  18.         echo 'var mapLat = '.$this->mapCoordinates->Lat.';';
  19.         echo 'var mapLong = '.$this->mapCoordinates->Lang.';';
  20.         echo 'var companyName = "'.$this->escape($this->businessObject->CompanyName).'";';
  21.         echo 'var mapZoom = '.Zend_Registry::get('config')->google->maps->idealZoom.';';
  22.         echo 'var useMarker = '.($this->useMapMarker == true ? 1 : 0).';';
  23.         echo 'var useMap = 1;';
  24.     }
  25.  
  26.     echo 'var businessId = '.$this->businessObject->ID.';';
  27.  
  28.     if (isset($this->mostRecentRating))
  29.     {
  30.         echo 'var mostRecentRating = true';
  31.     }
  32.  
  33.     if (isset($this->ratingJustAuthenticated))
  34.     {
  35.         echo 'var ratingJustAuthenticated = true';
  36.     }
  37. ?>
  38. </script>
  39. <!-- Facebook Pixel code - Page view events Code Start here -->
  40. <script>
  41.     fbq('track', 'ViewContent');
  42. </script>
  43. <!-- Facebook Pixel code - Page view events Code End here -->
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement