<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2016 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('restricted aceess'); AddonParser::addAddon('sp_accordion', 'sp_accordion_addon'); AddonParser::addAddon('sp_accordion_item', 'sp_accordion_item_addon'); $sppbAccordionStyle = ''; function sp_accordion_addon($atts, $content) { global $sppbAccordionStyle; extract(spAddonAtts(array("title" => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_fontweight" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', "style" => 'panel-default', "class" => ''), $atts)); $sppbAccordionStyle = $style; $output = '<div class="sppb-addon sppb-addon-accordion ' . $class . '">'; if ($title) { $title_style = ''; if ($title_margin_top != '') { $title_style .= 'margin-top:' . (int) $title_margin_top . 'px;'; } if ($title_margin_bottom != '') { $title_style .= 'margin-bottom:' . (int) $title_margin_bottom . 'px;'; } if ($title_text_color) { $title_style .= 'color:' . $title_text_color . ';'; } if ($title_fontsize) {
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('restricted aceess'); AddonParser::addAddon('sp_icon', 'sp_icon_addon'); function sp_icon_addon($atts) { extract(spAddonAtts(array('name' => '', 'alignment' => '', 'color' => '', 'size' => '', 'border_color' => '', 'border_width' => '', 'border_radius' => '', 'style' => '', 'background' => '', 'margin_top' => '', 'margin_bottom' => '', 'padding' => '', 'class' => ''), $atts)); $style = 'text-align:center;'; $font_size = ''; if ($name) { if ($margin_top) { $style .= 'margin-top:' . (int) $margin_top . 'px;'; } if ($margin_bottom) { $style .= 'margin-bottom:' . (int) $margin_bottom . 'px;'; } if ($padding) { $style .= 'padding:' . (int) $padding . 'px;'; } if ($color) { $style .= 'color:' . $color . ';'; } if ($background) { $style .= 'background-color:' . $background . ';';
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_carousel', 'sp_carousel_addon'); AddonParser::addAddon('sp_carousel_item', 'sp_carousel_item_addon'); function sp_carousel_addon($atts, $content) { extract(spAddonAtts(array('autoplay' => '', 'controllers' => '', 'arrows' => '', 'background' => '', 'color' => '', 'alignment' => '', "class" => ''), $atts)); if ($background) { $background = 'background-color:' . $background . ';'; } if ($color) { $color = 'color:' . $color . ';'; } $carousel_autoplay = $autoplay ? 'data-sppb-ride="sppb-carousel"' : ''; $output = '<div style="' . $background . $color . '" class="sppb-carousel sppb-slide ' . $class . '" ' . $carousel_autoplay . '>'; if ($controllers) { $output .= '<ol class="sppb-carousel-indicators">'; $output .= '</ol>'; } $output .= '<div class="sppb-carousel-inner ' . $alignment . '">'; $output .= AddonParser::spDoAddon($content); $output .= '</div>'; if ($arrows) {
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_image', 'sp_image_addon'); function sp_image_addon($atts) { extract(spAddonAtts(array('title' => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_fontweight" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', 'image' => '', 'position' => '', 'link' => '', 'target' => '', 'class' => ''), $atts)); $output = ''; if ($image) { $output .= '<div class="sppb-addon sppb-addon-single-image ' . $position . ' ' . $class . '">'; if ($title) { $title_style = ''; if ($title_margin_top != '') { $title_style .= 'margin-top:' . (int) $title_margin_top . 'px;'; } if ($title_margin_bottom != '') { $title_style .= 'margin-bottom:' . (int) $title_margin_bottom . 'px;'; } if ($title_text_color) { $title_style .= 'color:' . $title_text_color . ';'; } if ($title_fontsize) { $title_style .= 'font-size:' . $title_fontsize . 'px;line-height:' . $title_fontsize . 'px;'; }
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2016 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('restricted aceess'); AddonParser::addAddon('sp_button', 'sp_button_addon'); function sp_button_addon($atts, $content) { extract(spAddonAtts(array("text" => '', "url" => '', "size" => '', "type" => '', "icon" => '', "target" => '', "margin" => '', "block" => '', "class" => ''), $atts)); if ($icon != '') { $text = '<i class="fa ' . $icon . '"></i> ' . $text; } $style = ''; if ($margin) { $style = ' style="margin:' . $margin . ';"'; } $output = '<a target="' . $target . '" href="' . $url . '" class="sppb-btn sppb-btn-' . $type . ' sppb-btn-' . $size . ' ' . $block . ' ' . $class . '" ' . $style . ' role="button">' . $text . '</a>'; return $output; }
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_alert', 'sp_alert_addon'); function sp_alert_addon($atts) { extract(spAddonAtts(array("title" => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_fontweight" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', "close" => 'yes', "type" => 'info', "text" => '', "class" => ''), $atts)); $output = '<div class="sppb-addon sppb-addon-alert ' . $class . '">'; if ($title) { $title_style = ''; if ($title_margin_top != '') { $title_style .= 'margin-top:' . (int) $title_margin_top . 'px;'; } if ($title_margin_bottom != '') { $title_style .= 'margin-bottom:' . (int) $title_margin_bottom . 'px;'; } if ($title_text_color) { $title_style .= 'color:' . $title_text_color . ';'; } if ($title_fontsize) { $title_style .= 'font-size:' . $title_fontsize . 'px;line-height:' . $title_fontsize . 'px;'; } if ($title_fontweight) { $title_style .= 'font-weight:' . $title_fontweight . ';';
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_progress_bar', 'sp_progress_bar_addon'); function sp_progress_bar_addon($atts, $content) { extract(spAddonAtts(array("type" => '', "progress" => '', "text" => '', "stripped" => '', "active" => '', "class" => ''), $atts)); $output = '<div class="sppb-progress ' . $class . '">'; $output .= '<div class="sppb-progress-bar ' . $type . ' ' . $stripped . ' ' . $active . '" role="progressbar" aria-valuenow="' . (int) $progress . '" aria-valuemin="0" aria-valuemax="100" data-width="' . (int) $progress . '%">'; if ($text) { $output .= $text; } $output .= '</div>'; $output .= '</div>'; return $output; }
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_pricing', 'sp_pricing_addon'); function sp_pricing_addon($atts) { extract(spAddonAtts(array('title' => '', 'price' => '', 'duration' => '', 'pricing_content' => '', 'button_text' => '', 'button_url' => '', 'button_size' => '', 'button_type' => '', 'button_icon' => '', 'button_block' => '', 'alignment' => '', 'background' => '', 'color' => '', 'featured' => '', 'class' => ''), $atts)); $style = ''; if ($background) { $style .= 'background-color:' . $background . ';border-color: ' . $background . ';'; } if ($color) { $style .= 'color:' . $color . ';'; } if ($button_icon != '') { $button_text = '<i class="fa ' . $button_icon . '"></i> ' . $button_text; } $output = '<div class="sppb-addon sppb-addon-pricing-table ' . $alignment . ' ' . $class . '">'; $output .= '<div style="' . $style . '" class="sppb-pricing-box ' . $featured . '">'; $output .= '<div class="sppb-pricing-header">'; if ($title) { $output .= '<div class="sppb-pricing-title">' . $title . '</div>'; } if ($price) {
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_ajax_contact', 'sp_ajax_contact_addon'); function sp_ajax_contact_addon($atts) { extract(spAddonAtts(array("title" => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_fontweight" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', "recipient_email" => '*****@*****.**', "formcaptcha" => '', "captcha_question" => '', "captcha_answer" => '', "class" => ''), $atts)); $output = '<div class="sppb-addon sppb-addon-ajax-contact ' . $class . '">'; if ($title) { $title_style = ''; if ($title_margin_top != '') { $title_style .= 'margin-top:' . (int) $title_margin_top . 'px;'; } if ($title_margin_bottom != '') { $title_style .= 'margin-bottom:' . (int) $title_margin_bottom . 'px;'; } if ($title_text_color) { $title_style .= 'color:' . $title_text_color . ';'; } if ($title_fontsize) { $title_style .= 'font-size:' . $title_fontsize . 'px;line-height:' . $title_fontsize . 'px;'; } if ($title_fontweight) { $title_style .= 'font-weight:' . $title_fontweight . ';';
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2016 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('restricted aceess'); AddonParser::addAddon('sp_empty_space', 'sp_empty_space_addon'); function sp_empty_space_addon($atts) { extract(spAddonAtts(array('gap' => '20', 'hidden_md' => '', 'hidden_sm' => '', 'hidden_xs' => '', 'class' => ''), $atts)); //Responsive utilities if ($hidden_md) { $class .= $class . ' sppb-hidden-md sppb-hidden-lg'; } if ($hidden_sm) { $class .= $class . ' sppb-hidden-sm'; } if ($hidden_xs) { $class .= $class . ' sppb-hidden-xs'; } return '<div class="sppb-empty-space ' . $class . ' clearfix" style="margin-bottom:' . (int) $gap . 'px;"></div>'; }
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_tweet', 'sp_tweet_addon'); function sp_tweet_addon($atts) { extract(spAddonAtts(array('title' => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_fontweight" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', 'autoplay' => '', 'username' => '', 'consumerkey' => '', 'consumersecret' => '', 'accesstoken' => '', 'accesstokensecret' => '', 'include_rts' => '', 'ignore_replies' => '', 'show_username' => '', 'show_avatar' => '', 'count' => '', 'class' => ''), $atts)); if ($username == '') { $username = '******'; } if ($consumerkey == '') { return '<div class="sppb-alert sppb-alert-danger"><strong>Error</strong><br>Insert consumer key for twitter feed slider addon</div>'; } if ($consumersecret == '') { return '<div class="sppb-alert sppb-alert-danger"><strong>Error</strong><br>Insert consumer secrete key for twitter feed slider addon</div>'; } if ($accesstoken == '') { return '<div class="sppb-alert sppb-alert-danger"><strong>Error</strong><br>Insert access token for twitter feed slider addon</div>'; } if ($accesstokensecret == '') { return '<div class="sppb-alert sppb-alert-danger"><strong>Error</strong><br>Insert access token secrete key for twitter feed slider addon</div>'; } //Twitter helper file require_once JPATH_COMPONENT . '/helpers/tweet/helper.php';
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_text_block', 'sp_text_block_addon'); function sp_text_block_addon($atts) { extract(spAddonAtts(array("title" => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', "text" => '', "alignment" => '', 'class' => ''), $atts)); $output = '<div class="sppb-addon sppb-addon-text-block ' . $alignment . ' ' . $class . '">'; if ($title) { $title_style = ''; if ($title_margin_top) { $title_style .= 'margin-top:' . (int) $title_margin_top . 'px;'; } if ($title_margin_bottom) { $title_style .= 'margin-bottom:' . (int) $title_margin_bottom . 'px;'; } if ($title_text_color) { $title_style .= 'color:' . $title_text_color . ';'; } if ($title_fontsize) { $title_style .= 'font-size:' . $title_fontsize . 'px;line-height:' . $title_fontsize . 'px;'; } $output .= '<' . $heading_selector . ' class="sppb-addon-title" style="' . $title_style . '">' . $title . '</' . $heading_selector . '>'; }
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_dropcap', 'sp_dropcap_addon'); function sp_dropcap_addon($atts) { extract(spAddonAtts(array("title" => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_fontweight" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', "text" => '', 'class' => ''), $atts)); if ($text) { $output = '<div class="sppb-addon sppb-addon-dropcap ' . $class . '">'; if ($title) { $title_style = ''; if ($title_margin_top != '') { $title_style .= 'margin-top:' . (int) $title_margin_top . 'px;'; } if ($title_margin_bottom != '') { $title_style .= 'margin-bottom:' . (int) $title_margin_bottom . 'px;'; } if ($title_text_color) { $title_style .= 'color:' . $title_text_color . ';'; } if ($title_fontsize) { $title_style .= 'font-size:' . $title_fontsize . 'px;line-height:' . $title_fontsize . 'px;'; } if ($title_fontweight) {
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_twitter_share', 'sp_twitter_share_addon'); function sp_twitter_share_addon($atts) { extract(spAddonAtts(array('showcount' => '', 'size' => ''), $atts)); $output = ''; if (!defined('_SPPB_TWITTER')) { define('_SPPB_TWITTER', 1); $output .= "<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+'://platform.twitter.com/widgets.js';fjs.parentNode.insertBefore(js,fjs);}}(document, 'script', 'twitter-wjs');</script>"; } $data = ''; if (!$showcount) { $data .= ' data-count="none"'; } if ($size == 'large') { $data .= ' data-size="large"'; } $output .= '<a href="' . JURI::current() . '" class="twitter-share-button" ' . $data . '>Tweet</a>'; return $output; }
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_person', 'sp_person_addon'); function sp_person_addon($atts) { extract(spAddonAtts(array('image' => '', 'name' => '', 'designation' => '', 'introtext' => '', 'facebook' => '', 'twitter' => '', 'google_plus' => '', 'youtube' => '', 'linkedin' => '', 'pinterest' => '', 'flickr' => '', 'dribbble' => '', 'behance' => '', 'instagram' => '', 'social_position' => '', 'alignment' => '', 'class' => ''), $atts)); $output = ''; $social_icons = ''; if ($facebook || $twitter || $google_plus || $youtube || $linkedin || $pinterest || $flickr || $dribbble || $behance || $instagram) { $social_icons .= '<div class="sppb-person-social-icons">'; $social_icons .= '<ul class="sppb-person-social">'; if ($facebook) { $social_icons .= '<li><a target="_blank" href="' . $facebook . '"><i class="fa fa-facebook"></i></a></li>'; } if ($twitter) { $social_icons .= '<li><a target="_blank" href="' . $twitter . '"><i class="fa fa-twitter"></i></a></li>'; } if ($google_plus) { $social_icons .= '<li><a target="_blank" href="' . $google_plus . '"><i class="fa fa-google-plus"></i></a></li>'; } if ($youtube) { $social_icons .= '<li><a target="_blank" href="' . $youtube . '"><i class="fa fa-youtube"></i></a></li>'; }
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_animated_number', 'sp_animated_number_addon'); function sp_animated_number_addon($atts) { extract(spAddonAtts(array('number' => '', 'duration' => '', 'font_size' => '', 'border_color' => '', 'border_width' => '', 'border_radius' => '', 'color' => '', 'background' => '', 'counter_title' => '', 'title_font_size' => '', 'counter_color' => '', 'alignment' => '', 'class' => ''), $atts)); $style = ''; $number_style = ''; $text_style = ''; if ($background) { $class .= $class . ' sppb-hasbg'; } if ($background) { $style .= 'background-color:' . $background . ';'; } if ($border_color) { $style .= 'border-style:solid;border-color:' . $border_color . ';'; } if ($border_width) { $style .= 'border-width:' . (int) $border_width . 'px;'; } if ($border_radius) { $style .= 'border-radius:' . (int) $border_radius . 'px;';
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_testimonial', 'sp_testimonial_addon'); function sp_testimonial_addon($atts, $content) { extract(spAddonAtts(array("title" => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', "review" => '', "name" => '', "company" => '', "avatar" => '', "avatar_width" => '', "avatar_position" => 'left', "link" => '', "link_target" => '', "class" => ''), $atts)); $output = '<div class="sppb-addon sppb-addon-testimonial ' . $class . '">'; if ($title) { $title_style = ''; if ($title_margin_top) { $title_style .= 'margin-top:' . (int) $title_margin_top . 'px;'; } if ($title_margin_bottom) { $title_style .= 'margin-bottom:' . (int) $title_margin_bottom . 'px;'; } if ($title_text_color) { $title_style .= 'color:' . $title_text_color . ';'; } if ($title_fontsize) { $title_style .= 'font-size:' . $title_fontsize . 'px;line-height:' . $title_fontsize . 'px;'; } $output .= '<' . $heading_selector . ' class="sppb-addon-title" style="' . $title_style . '">' . $title . '</' . $heading_selector . '>'; }
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_modal', 'sp_modal_addon'); function sp_modal_addon($atts) { extract(spAddonAtts(array('modal_selector' => '', 'button_text' => '', 'button_size' => '', 'button_type' => '', 'button_icon' => '', 'button_block' => '', 'selector_image' => '', 'selector_icon_name' => '', 'selector_icon_size' => '', 'selector_icon_color' => '', 'selector_icon_background' => '', 'selector_icon_border_color' => '', 'selector_icon_border_width' => '', 'selector_icon_border_radius' => '', 'selector_icon_padding' => '', 'selector_margin_top' => '', 'selector_margin_bottom' => '', 'alignment' => '', 'modal_unique_id' => 'mymodal', 'modal_content_type' => 'text', 'modal_content_text' => '', 'modal_content_image' => '', 'modal_content_video_url' => '', 'modal_popup_width' => '', 'modal_popup_height' => '', 'class' => ''), $atts)); $doc = JFactory::getDocument(); $doc->addStylesheet(JURI::base(true) . '/components/com_sppagebuilder/assets/css/prettyPhoto.css'); $doc->addStylesheet(JURI::base(true) . '/components/com_sppagebuilder/assets/css/sppb-prettyphoto.css'); $doc->addScript(JURI::base(true) . '/components/com_sppagebuilder/assets/js/jquery.prettyPhoto.js'); $doc->addScriptdeclaration('jQuery(function($){ $(document).ready(function(){ $("#' . $modal_unique_id . '").prettyPhoto({ social_tools: false, theme: "sppb_prettyphoto", horizontal_padding: 20, allow_resize: true, default_width: ' . $modal_popup_width . ', default_height: ' . $modal_popup_height . ' }); }); })'); $output = '';
<?php defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_testimonialpro', 'sp_testimonialpro_addon'); AddonParser::addAddon('sp_testimonialpro_item', 'sp_testimonialpro_item_addon'); function sp_testimonialpro_addon($atts, $content) { extract(spAddonAtts(array('autoplay' => '', 'arrows' => '', "class" => ''), $atts)); $carousel_autoplay = $autoplay ? 'data-sppb-ride="sppb-carousel"' : ''; $output = '<div class="sppb-carousel sppb-testimonial-pro sppb-slide ' . $class . ' sppb-text-center" ' . $carousel_autoplay . '>'; $output .= '<div class="sppb-carousel-inner">'; $output .= AddonParser::spDoAddon($content); $output .= '</div>'; if ($arrows) { $output .= '<a class="left sppb-carousel-control" role="button" data-slide="prev"><i class="fa fa-angle-left"></i></a>'; $output .= '<a class="right sppb-carousel-control" role="button" data-slide="next"><i class="fa fa-angle-right"></i></a>'; } $output .= '</div>'; return $output; } function sp_testimonialpro_item_addon($atts) { extract(spAddonAtts(array("title" => '', "avatar" => '', "avatar_style" => '', 'message' => '', "url" => ''), $atts)); $output = '<div class="sppb-item">'; $title = '<strong class="pro-client-name">' . $title . '</strong>'; if ($url) { $title .= ' - <span class="pro-client-url">' . $url . '</span>'; } if ($avatar) { $output .= '<img class="sppb-img-responsive sppb-avatar ' . $avatar_style . '" src="' . $avatar . '" alt="">'; }
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_blocknumber', 'sp_blocknumber_addon'); function sp_blocknumber_addon($atts) { extract(spAddonAtts(array("title" => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_fontweight" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', "heading" => '', "text" => '', "number" => '', "size" => '', "background" => '', "color" => '', "border_radius" => '', "alignment" => '', 'class' => ''), $atts)); $style = ''; $block_number = ''; if ($number) { if ($size) { $style .= 'width: ' . (int) $size . 'px; height: ' . (int) $size . 'px; line-height: ' . (int) $size . 'px;'; } if ($background) { $style .= 'background-color: ' . $background . ';'; } if ($color) { $style .= 'color: ' . $color . ';'; } if ($border_radius) { $style .= 'border-radius: ' . (int) $border_radius . 'px;'; } $block_number .= '<span class="sppb-blocknumber-number" style="' . $style . '">' . $number . '</span>'; }
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_audio', 'sp_audio_addon'); function sp_audio_addon($atts, $content) { extract(spAddonAtts(array("title" => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_fontweight" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', "mp3_link" => '', "ogg_link" => '', "autoplay" => '', "repeat" => '', "class" => ''), $atts)); $output = '<div class="sppb-addon sppb-addon-audio ' . $class . '">'; if ($title) { $title_style = ''; if ($title_margin_top != '') { $title_style .= 'margin-top:' . (int) $title_margin_top . 'px;'; } if ($title_margin_bottom != '') { $title_style .= 'margin-bottom:' . (int) $title_margin_bottom . 'px;'; } if ($title_text_color) { $title_style .= 'color:' . $title_text_color . ';'; } if ($title_fontsize) { $title_style .= 'font-size:' . $title_fontsize . 'px;line-height:' . $title_fontsize . 'px;'; } if ($title_fontweight) { $title_style .= 'font-weight:' . $title_fontweight . ';';
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('restricted aceess'); AddonParser::addAddon('sp_video', 'sp_video_addon'); function sp_video_addon($atts) { extract(spAddonAtts(array("title" => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_fontweight" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', "url" => '', "class" => ''), $atts)); if ($url) { $video = parse_url($url); switch ($video['host']) { case 'youtu.be': $id = trim($video['path'], '/'); $src = '//www.youtube.com/embed/' . $id; break; case 'www.youtube.com': case 'youtube.com': parse_str($video['query'], $query); $id = $query['v']; $src = '//www.youtube.com/embed/' . $id; break; case 'vimeo.com': case 'www.vimeo.com': $id = trim($video['path'], '/'); $src = "//player.vimeo.com/video/{$id}";
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_feature', 'sp_feature_addon'); function sp_feature_addon($atts) { extract(spAddonAtts(array("title" => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_fontweight" => '', "title_text_color" => '', "title_url" => '', "title_position" => 'before', "feature_type" => 'icon', "feature_image" => '', 'icon_name' => '', 'icon_color' => '', 'icon_size' => '', 'icon_border_color' => '', 'icon_border_width' => '', 'icon_border_radius' => '', 'icon_style' => '', 'icon_background' => '', 'icon_margin_top' => '', 'icon_margin_bottom' => '', 'icon_padding' => '', 'text' => '', 'alignment' => '', 'class' => ''), $atts)); //Image or icon position if ($title_position == 'before') { $icon_image_position = 'after'; } else { if ($title_position == 'after') { $icon_image_position = 'before'; } else { $icon_image_position = $title_position; } } //Reset Alignment for left and right style if ($icon_image_position == 'left' || $icon_image_position == 'right') { $alignment = 'sppb-text-' . $icon_image_position; } //Icon or Image $media = ''; if ($feature_type == 'icon') {
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_image_content', 'sp_image_content_addon'); function sp_image_content_addon($atts) { extract(spAddonAtts(array("image" => '', "image_width" => '', "image_alignment" => '', "title" => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_fontweight" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', "text" => '', "button_text" => '', "button_url" => '', "button_size" => '', "button_type" => '', "button_icon" => '', "button_block" => '', "button_target" => '', "class" => ''), $atts)); if ($image_alignment == 'left') { $eontent_class = ' sppb-col-sm-offset-6'; } else { $eontent_class = ''; } if ($image && $title) { $output = '<div class="sppb-addon sppb-addon-image-content aligment-' . $image_alignment . ' clearfix ' . $class . '">'; //Image $output .= '<div style="background-image: url(' . JURI::base(true) . '/' . $image . ');" class="sppb-image-holder">'; $output .= '</div>'; //Content $output .= '<div class="sppb-container">'; $output .= '<div class="sppb-row">'; $output .= '<div class="sppb-col-sm-6' . $eontent_class . '">'; $output .= '<div class="sppb-content-holder">'; $title_style = ''; if ($title_margin_top != '') {
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_divider', 'sp_divider_addon'); function sp_divider_addon($atts, $content) { extract(spAddonAtts(array('divider_type' => '', 'margin_top' => '', 'margin_bottom' => '', 'border_color' => '', 'border_style' => '', 'border_width' => '', 'divider_image' => '', 'background_repeat' => '', 'background_position' => '', 'divider_height' => '', 'class' => ''), $atts)); $style = ''; $style1 = ''; $style2 = ''; if ($margin_top) { $style .= 'margin-top:' . (int) $margin_top . 'px;'; } if ($margin_bottom) { $style .= 'margin-bottom:' . (int) $margin_bottom . 'px;'; } if ($border_color) { $style1 .= 'border-bottom-color:' . $border_color . ';'; } if ($border_style) { $style1 .= 'border-bottom-style:' . $border_style . ';'; } if ($border_width) { $style1 .= 'border-bottom-width:' . (int) $border_width . 'px;';
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_gallery', 'sp_gallery_addon'); AddonParser::addAddon('sp_gallery_item', 'sp_gallery_item_addon'); $sppbGalleryParam = array(); function sp_gallery_addon($atts, $content) { global $sppbGalleryParam; $doc = JFactory::getDocument(); $doc->addStylesheet(JURI::base(true) . '/components/com_sppagebuilder/assets/css/prettyPhoto.css'); $doc->addStylesheet(JURI::base(true) . '/components/com_sppagebuilder/assets/css/sppb-prettyPhoto.css'); $doc->addScript(JURI::base(true) . '/components/com_sppagebuilder/assets/js/jquery.prettyPhoto.js'); $doc->addScriptdeclaration('jQuery(function($){ $(document).ready(function(){ $("a[rel^=\'prettyPhoto\']").prettyPhoto({ social_tools: false, theme: "sppb_prettyphoto", horizontal_padding: 20, overlay_gallery: false }); }); })'); extract(spAddonAtts(array('title' => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_fontweight" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', 'width' => '', 'height' => '', "class" => ''), $atts));
<?php defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_call_to_action', 'sp_call_to_action_addon'); function sp_call_to_action_addon($atts) { extract(spAddonAtts(array("title" => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', "subtitle_fontsize" => '', "subtitle" => '', "subtitle_text_color" => '', "text" => '', "background" => '', "color" => '', "padding" => '', "button_text" => '', "button_url" => '', "button_size" => '', "button_type" => '', "button_icon" => '', "button_block" => '', "button_target" => '', "button_position" => '', "class" => ''), $atts)); $style = ''; if ($button_icon) { $button_text = '<i class="fa ' . $button_icon . '"></i> ' . $button_text; } if ($background) { $style .= 'background-color: ' . $background . ';padding:40px 20px;'; } if ($color) { $style .= 'color: ' . $color . ';'; } if ($padding) { $style .= 'padding: ' . (int) $padding . 'px;'; } $button_output = '<a target="' . $button_target . '" href="' . $button_url . '" class="sppb-btn sppb-btn-' . $button_type . ' sppb-btn-' . $button_size . ' ' . $button_block . '" role="button">' . $button_text . '</a>'; $output = '<div class="sppb-addon sppb-addon-cta ' . $class . '" style="' . $style . '">'; if ($button_position == 'right') { $output .= '<div class="sppb-row">'; $output .= '<div class="sppb-col-sm-8">'; if ($title) { $title_style = ''; if ($title_margin_top) { $title_style .= 'margin-top:' . (int) $title_margin_top . 'px;'; } if ($title_margin_bottom) {
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('restricted aceess'); AddonParser::addAddon('sp_module', 'sp_module_addon'); function sp_module_addon($atts) { extract(spAddonAtts(array('id' => '', 'module_type' => 'module', 'position' => '', 'title' => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_fontweight" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', 'class' => ''), $atts)); if ($module_type == 'position' && !$position || $module_type == 'module' && !$id) { return; } //Query Module $app = JFactory::getApplication(); $user = JFactory::getUser(); $groups = implode(',', $user->getAuthorisedViewLevels()); $lang = JFactory::getLanguage()->getTag(); $clientId = (int) $app->getClientId(); $db = JFactory::getDbo(); $query = $db->getQuery(true); $query->select('m.id, m.title, m.module, m.position, m.ordering, m.content, m.showtitle, m.params'); $query->from('#__modules AS m'); $query->where('m.published = 1'); if ($module_type == 'position') { $query->where($db->quoteName('m.position') . ' = ' . $db->quote($position)); $query->order('m.ordering ASC');
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_tab', 'sp_tab_addon'); AddonParser::addAddon('sp_tab_item', 'sp_tab_item_addon'); $sppbTabArray = array(); function sp_tab_addon($atts, $content) { global $sppbTabArray; extract(spAddonAtts(array("title" => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_fontweight" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', "style" => '', "class" => ''), $atts)); AddonParser::spDoAddon($content); $output = '<div class="sppb-addon sppb-addon-tab ' . $class . '">'; if ($title) { $title_style = ''; if ($title_margin_top != '') { $title_style .= 'margin-top:' . (int) $title_margin_top . 'px;'; } if ($title_margin_bottom != '') { $title_style .= 'margin-bottom:' . (int) $title_margin_bottom . 'px;'; } if ($title_text_color) { $title_style .= 'color:' . $title_text_color . ';'; } if ($title_fontsize) {
<?php /** * @package SP Page Builder * @author JoomShaper http://www.joomshaper.com * @copyright Copyright (c) 2010 - 2015 JoomShaper * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or later */ //no direct accees defined('_JEXEC') or die('resticted aceess'); AddonParser::addAddon('sp_soundcloud', 'sp_soundcloud_addon'); function sp_soundcloud_addon($atts) { extract(spAddonAtts(array("title" => '', "heading_selector" => 'h3', "title_fontsize" => '', "title_fontweight" => '', "title_text_color" => '', "title_margin_top" => '', "title_margin_bottom" => '', "embed" => '', "class" => ''), $atts)); if ($embed) { $output = '<div class="sppb-addon sppb-addon-soundcloud ' . $class . '">'; if ($title) { $title_style = ''; if ($title_margin_top != '') { $title_style .= 'margin-top:' . (int) $title_margin_top . 'px;'; } if ($title_margin_bottom != '') { $title_style .= 'margin-bottom:' . (int) $title_margin_bottom . 'px;'; } if ($title_text_color) { $title_style .= 'color:' . $title_text_color . ';'; } if ($title_fontsize) { $title_style .= 'font-size:' . $title_fontsize . 'px;line-height:' . $title_fontsize . 'px;'; } if ($title_fontweight) {