Server : LiteSpeed System : Linux server 3.10.0-1160.90.1.el7.x86_64 #1 SMP Thu May 4 15:21:22 UTC 2023 x86_64 User : alsaif ( 1057) PHP Version : 7.4.33 Disable Function : show_source,posix_kill,posix_mkfifo,posix_getpwuid,posix_setpgid,posix_setsid,posix_setuid,posix_setgid,posix_seteuid,posix_setegid,posix_uname Directory : /home/alsaif/domains/alsaif.group/public_html/templates/startsik/features/ |
<?php
/**
* @package Helix Ultimate Framework
* @author JoomShaper https://www.joomshaper.com
* @copyright Copyright (c) 2010 - 2018 JoomShaper
* @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or Later
*/
defined ('_JEXEC') or die();
class HelixUltimateFeatureContact
{
private $params;
public function __construct($params)
{
$this->params = $params;
$this->position = $this->params->get('contact_position', 'top1');
}
public function renderFeature()
{
$conditions = $this->params->get('contactinfo') && ($this->params->get('contact_phone') || $this->params->get('contact_fax') || $this->params->get('contact_email') || $this->params->get('contact_time') || $this->params->get('contact_address'));
if($conditions)
{
$output = '<ul class="sp-contact-info">';
if($this->params->get('contact_address'))
{
$output .= '<p> ' . $this->params->get('contact_address') . '</p>';
}
if($this->params->get('contact_phone'))
{
$output .= '<li class="sp-contact-fax"><span class="fa fa-phone" aria-hidden="true"></span> <label>Phone Number</label><a href="tel:' . str_replace(array(')','(',' ','-'),array('','','',''), $this->params->get('contact_phone')) . '">' . $this->params->get('contact_phone') . '</a></li>';
}
if($this->params->get('contact_fax'))
{
$output .= '<li class="sp-contact-fax"><span class="fa fa-fax" aria-hidden="true"></span> <label>Fax</label><a href="tel:' . str_replace(array(')','(',' ','-'),array('','','',''), $this->params->get('contact_fax')) . '">' . $this->params->get('contact_fax') . '</a></li>';
}
if($this->params->get('contact_email'))
{
$output .= '<li class="sp-contact-email"><span class="fa fa-envelope" aria-hidden="true"></span> <label>Email Adress</label> <a href="mailto:'. $this->params->get('contact_email') .'">' . $this->params->get('contact_email') . '</a></li>';
}
if($this->params->get('contact_time'))
{
$output .= '<li class="sp-contact-time"><span class="fa fa-clock-o" aria-hidden="true"></span><label>Office Hour</label> ' . $this->params->get('contact_time') . '</li>';
}
$output .= '</ul>';
return $output;
}
}
}