| Current Path : /home/helpink/www/components/com_jbusinessdirectory/views/event/tmpl/ |
| Current File : /home/helpink/www/components/com_jbusinessdirectory/views/event/tmpl/default_style_3.php |
<?php
/**
* @package J-BusinessDirectory
*
* @author CMSJunkie http://www.cmsjunkie.com/
* @copyright Copyright (C) 2007 - 2022 CMSJunkie. All rights reserved.
* @license https://www.gnu.org/licenses/agpl-3.0.en.html
*/
defined('_JEXEC') or die('Restricted access');
// Initialize required variables and files
$session = JFactory::getSession();
$menuItem = "&Itemid=" . $session->get("eventsMenuItemId");
$referer = isset($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] : "";
require_once 'header.php';
require_once BD_CLASSES_PATH . '/attributes/attributeservice.php';
require_once HELPERS_PATH . '/event_styles.php';
?>
<div id="jbd-container" class="jbd-container">
<div id="event-details-3" class="event-details-3 event-container" itemscope itemtype="http://schema.org/Event">
<div class="container py-3">
<div class="row align-items-center justify-content-between">
<!-- Left: Back Link -->
<div class="col-auto">
<a href="#" class="text-danger text-decoration-none">
<?php if (!empty($referer) && false) { ?>
<i class="la la-angle-left"></i> <a href="<?php echo $referer ?>"> ← <?php echo JText::_("BACK") ?></a>
<?php } else { ?>
<a href="<?php echo JRoute::_('index.php?option=com_jbusinessdirectory&view=events&reload=1' . $menuItem); ?>">
<i class="la la-angle-left"></i> <?php echo JText::_("BACK_TO_EVENTS") ?>
</a>
<?php } ?>
</a>
</div>
<!-- Center: Title & Contact Info -->
<div class="col text-center">
<h1 itemprop="name"><?php echo $this->escape($this->event->name) ?></h1>
<!-- Event URL (Hidden) -->
<span style="display:none;" itemprop="url">
<?php echo JBusinessUtil::getEventLink($this->event->id, $this->event->alias); ?>
</span>
<p class="text-muted mb-2">
<i class="la la-map-marker text-danger"></i> 123 Yonge Street, Queens County, M5H, Prince Edward Island, Canada
</p>
<div class="d-flex justify-content-center gap-3">
<span class="d-flex align-items-center gap-2 bg-light p-2 rounded-pill">
<i class="la la-phone text-secondary"></i> +1 555 888 9932
</span>
<span class="d-flex align-items-center gap-2 bg-light p-2 rounded-pill">
<i class="la la-envelope text-secondary"></i> example@gmail.com
</span>
</div>
</div>
<!-- Right: Icons -->
<div class="col-auto d-flex gap-2">
<!-- Event Header Icons -->
<?php echo JBDEventsStyles::getEventHeaderIcons($this->event); ?>
</div>
</div>
<!-- Event Image Schema -->
<span style="display:none;" itemprop="image" itemscope itemtype="http://schema.org/ImageObject">
<?php if (!empty($picturePath)) { ?>
<img alt="<?php echo $this->escape($this->event->name) ?>"
src="<?php echo BD_PICTURES_PATH . $picturePath ?>"
itemprop="contentUrl">
<span style="display:none;" itemprop="url">
<?php echo BD_PICTURES_PATH . $picturePath ?>
</span>
<?php } else { ?>
<img title="<?php echo $this->escape($this->event->name) ?>"
alt="<?php echo $this->event->name ?>"
src="<?php echo BD_PICTURES_PATH . '/no_image.jpg' ?>"
itemprop="contentUrl">
<span style="display:none;" itemprop="url">
<?php echo BD_PICTURES_PATH . '/no_image.jpg' ?>
</span>
<?php } ?>
</span>
</div>
<!-- Event Pictures Gallery -->
<?php if (!empty($this->event->pictures)) { ?>
<div class="row">
<div class="col-12">
<?php
$this->pictures = $this->event->pictures;
require_once JPATH_COMPONENT_SITE . '/include/gallery/image_gallery_carousel.php';
?>
</div>
</div>
<?php } ?>
<!-- Main Content Section -->
<div class="row item-section">
<!-- Left Column - Main Content -->
<div class="col-lg-8">
<!-- Event Description -->
<div class="event-content-box">
<div class="box-title"><?php echo JText::_("LNG_DESCRIPTION") ?></div>
<div itemprop="description">
<?php echo JHTML::_("content.prepare", $this->event->description); ?>
</div>
<!-- Event Categories -->
<?php if (!empty($this->event->categories)) { ?>
<div class="categories-wrapper">
<?php foreach ($this->event->categories as $category) { ?>
<a href="<?php echo JBusinessUtil::getEventCategoryLink($category[0], $category[2]) ?>">
<?php echo $this->escape($category[1]) ?>
</a>
<?php } ?>
</div>
<?php } ?>
<!-- Event Attributes -->
<div class="classification">
<?php require_once 'event_attributes.php'; ?>
</div>
<!-- Event Videos -->
<?php require_once 'event_videos.php'; ?>
</div>
<!-- Event Tickets Section -->
<?php if (!empty($this->eventTickets) && $this->appSettings->enable_event_reservation) { ?>
<div class="event-content-box">
<div class="box-title"><?php echo JText::_("LNG_EVENT_TICKETS") ?></div>
<?php require_once 'event_tickets.php'; ?>
</div>
<?php } ?>
<!-- Event Attachments -->
<?php if ($this->appSettings->enable_attachments && !empty($this->event->attachments)) { ?>
<div class="event-content-box">
<div class="box-title"><?php echo JText::_("LNG_ATTACHMENTS") ?></div>
<?php require "event_attachments.php" ?>
</div>
<?php } ?>
<!-- Associated Companies -->
<?php if (!empty($this->associatedCompanies)) { ?>
<div class="event-content-box">
<div class="box-title"><?php echo JText::_("LNG_ASSOCIATED_COMPANIES") ?></div>
<?php require_once 'event_associated_companies.php'; ?>
</div>
<?php } ?>
<!-- Event Modules -->
<?php
jimport('joomla.application.module.helper');
$modules = JModuleHelper::getModules('event-details');
if (!empty($modules)) {
?>
<div class="event-modules">
<?php foreach ($modules as $module) {
echo JModuleHelper::renderModule($module, array("style" => "xhtml"));
} ?>
</div>
<?php } ?>
</div>
<!-- Right Column - Event Details -->
<div class="col-lg-4">
<!-- Ticket Booking Button -->
<?php if (!empty($this->event->ticket_url) && $this->defaultAttributes["ticket_url"] != ATTRIBUTE_NOT_SHOW) { ?>
<a class="book-tickets" target="_blank" href="<?php echo $this->escape($this->event->ticket_url) ?>">
<?php echo JText::_("LNG_BOOK_TICKETS") ?>
</a>
<?php } ?>
<!-- Event Details Box -->
<div class="event-content-box">
<div class="box-title"><?php echo JText::_("LNG_EVENT_DETAILS") ?></div>
<?php
echo JBDEventsStyles::getEventDetails($this->event, $this->defaultAttributes, $this->appSettings, $showData);
echo JBDEventsStyles::getEventInfo($this->event, $this->defaultAttributes, $this->appSettings, $user, $this->userAssociatedCompanies);
?>
</div>
<!-- Location Section -->
<div class="event-content-box">
<div class="box-title"><?php echo JText::_("LNG_LOCATION") ?></div>
<!-- Map -->
<?php if (!empty($this->event->latitude) && !empty($this->event->longitude)) { ?>
<div id="event-map">
<?php require_once 'map.php'; ?>
</div>
<?php } ?>
<!-- Address -->
<?php
$address = JBusinessUtil::getAddressText($this->event);
if (!empty($address)) {
?>
<div class="event-location" itemprop="location" itemscope itemtype="http://schema.org/Place">
<i class="icon map-marker"></i>
<div>
<span itemprop="name"><?php echo $this->escape($address) ?></span>
<span style="display:none" itemprop="address">
<?php echo JBusinessUtil::getAddressText($this->event) ?>
</span>
<!-- Directions Link -->
<?php if (!empty($this->event->latitude) && !empty($this->event->longitude)) {
$location = new stdClass;
$location->latitude = $this->event->latitude;
$location->longitude = $this->event->longitude;
?>
- <a target="_blank" href="<?php echo JBusinessUtil::getDirectionURL(null, $location) ?>">
<?php echo JText::_("LNG_GET_MAP_DIRECTIONS") ?>
</a>
<?php } ?>
</div>
</div>
<?php } ?>
</div>
<!-- Organizer Section -->
<?php if (!empty($this->event->company)) { ?>
<div class="event-content-box">
<div class="box-title"><?php echo JText::_("LNG_ORGANIZER") ?></div>
<!-- Organizer Details -->
<div class="organizer-details" itemprop="organizer" itemscope itemtype="http://schema.org/Organization">
<!-- Company Logo -->
<div class="business-logo">
<?php if (!empty($this->event->company->logoLocation)) { ?>
<img src="<?php echo BD_PICTURES_PATH . $this->event->company->logoLocation ?>"
alt="<?php echo $this->event->company->name ?>">
<?php } else { ?>
<img src="<?php echo BD_PICTURES_PATH . '/no_image.jpg' ?>"
alt="<?php echo !empty($this->event->company) ? $this->event->company->name : "" ?>">
<?php } ?>
</div>
<!-- Company Details -->
<div class="business-details">
<a itemprop="url" target="_blank" href="<?php echo JBusinessUtil::getCompanyLink($this->event->company) ?>">
<span itemprop="name"><?php echo $this->escape($this->event->company->name) ?></span>
</a>
<div class="rating rating-stars">
<span class="user-rating-avg rating-average-review"
id="rating-average-review"
title="<?php echo $this->event->company->review_score ?>"
style="display: block;"></span>
</div>
</div>
</div>
<!-- Company Actions -->
<div class="business-actions">
<div class="business-item">
<a class="btn btn-outline" target="_blank"
href="<?php echo JBusinessUtil::getCompanyLink($this->event->company) ?>">
<?php echo JText::_("LNG_VIEW_PROFILE") ?>
</a>
</div>
<?php if (!empty($this->event->company->website)) { ?>
<div class="business-item" itemprop="url">
<a class="btn btn-primary" target="_blank"
itemprop="url"
title="<?php echo $this->escape($this->event->company->name) ?> Website"
onclick="jbdUtils.registerStatAction(<?php echo $this->event->company->id ?>,
<?php echo STATISTIC_ITEM_BUSINESS ?>,
<?php echo STATISTIC_TYPE_WEBSITE_CLICK ?>)"
href="<?php echo $this->escape($this->event->company->website) ?>">
<?php echo JText::_('LNG_VISIT_WEBSITE') ?>
</a>
</div>
<?php } ?>
</div>
</div>
<?php } ?>
</div>
</div>
</div>
</div>
<?php require_once 'event_util.php'; ?>