| Server IP : 104.26.5.103 / Your IP : 216.73.216.4 Web Server : nginx/1.27.1 System : Linux in-5 5.15.0-143-generic #153-Ubuntu SMP Fri Jun 13 19:10:45 UTC 2025 x86_64 User : arabianexpress ( 1872) PHP Version : 8.0.30 Disable Function : exec,passthru,shell_exec,system,proc_open,popen,parse_ini_file,show_source MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /storage/v9321/leapdubai/public_html/wp-content/plugins/printx-core/include/elementor/ |
Upload File : |
<?php
namespace TPCore\Widgets;
use Elementor\Widget_Base;
use Elementor\Controls_Manager;
use \Elementor\Group_Control_Background;
use \Elementor\Group_Control_Image_Size;
use \Elementor\Repeater;
use \Elementor\Utils;
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
/**
* Tp Core
*
* Elementor widget for hello world.
*
* @since 1.0.0
*/
class TP_Process extends Widget_Base {
use \TPCore\Widgets\TPCoreElementFunctions;
/**
* Retrieve the widget name.
*
* @since 1.0.0
*
* @access public
*
* @return string Widget name.
*/
public function get_name() {
return 'process';
}
/**
* Retrieve the widget title.
*
* @since 1.0.0
*
* @access public
*
* @return string Widget title.
*/
public function get_title() {
return __( 'Process', 'tpcore' );
}
/**
* Retrieve the widget icon.
*
* @since 1.0.0
*
* @access public
*
* @return string Widget icon.
*/
public function get_icon() {
return 'tp-icon';
}
/**
* Retrieve the list of categories the widget belongs to.
*
* Used to determine where to display the widget in the editor.
*
* Note that currently Elementor supports only one category.
* When multiple categories passed, Elementor uses the first one.
*
* @since 1.0.0
*
* @access public
*
* @return array Widget categories.
*/
public function get_categories() {
return [ 'tpcore' ];
}
/**
* Retrieve the list of scripts the widget depended on.
*
* Used to set scripts dependencies required to run the widget.
*
* @since 1.0.0
*
* @access public
*
* @return array Widget scripts dependencies.
*/
public function get_script_depends() {
return [ 'tpcore' ];
}
/**
* Register the widget controls.
*
* Adds different input fields to allow the user to change and customize the widget settings.
*
* @since 1.0.0
*
* @access protected
*/
protected function register_controls(){
$this->register_controls_section();
$this->style_tab_content();
}
protected function register_controls_section() {
// layout Panel
$this->start_controls_section(
'tp_layout',
[
'label' => esc_html__('Design Layout', 'tpcore'),
]
);
$this->add_control(
'tp_design_style',
[
'label' => esc_html__('Select Layout', 'tpcore'),
'type' => Controls_Manager::SELECT,
'options' => [
'layout-1' => esc_html__('Layout 1', 'tpcore'),
'layout-2' => esc_html__('Layout 2', 'tpcore'),
'layout-3' => esc_html__('Layout 3', 'tpcore'),
'layout-4' => esc_html__('Layout 4', 'tpcore'),
'layout-5' => esc_html__('Layout 5', 'tpcore'),
'layout-6' => esc_html__('Layout 6', 'tpcore'),
'layout-7' => esc_html__('Layout 7', 'tpcore'),
'layout-8' => esc_html__('Layout 8', 'tpcore'),
'layout-9' => esc_html__('Layout 9', 'tpcore'),
'layout-10' => esc_html__('Layout 10', 'tpcore'),
],
'default' => 'layout-1',
]
);
$this->end_controls_section();
// Process group
$this->start_controls_section(
'tp_process',
[
'label' => esc_html__('Process List', 'tpcore'),
'description' => esc_html__( 'Control all the style settings from Style tab', 'tpcore' ),
'tab' => \Elementor\Controls_Manager::TAB_CONTENT,
]
);
$repeater = new \Elementor\Repeater();
$repeater->add_control(
'repeater_condition',
[
'label' => __( 'Field condition', 'tpcore' ),
'type' => Controls_Manager::SELECT,
'options' => [
'style_1' => __( 'Style 1', 'tpcore' ),
'style_2' => __( 'Style 2', 'tpcore' ),
'style_3' => __( 'Style 3', 'tpcore' ),
'style_4' => __( 'Style 4', 'tpcore' ),
'style_5' => __( 'Style 5', 'tpcore' ),
'style_6' => __( 'Style 6', 'tpcore' ),
'style_7' => __( 'Style 7', 'tpcore' ),
'style_8' => __( 'Style 8', 'tpcore' ),
'style_9' => __( 'Style 9', 'tpcore' ),
'style_10' => __( 'Style 10', 'tpcore' ),
],
'default' => 'style_1',
'frontend_available' => true,
'style_transfer' => true,
]
);
$repeater->add_control(
'tp_box_icon_type',
[
'label' => esc_html__('Select Icon Type', 'tpcore'),
'type' => \Elementor\Controls_Manager::SELECT,
'default' => 'icon',
'options' => [
'image' => esc_html__('Image', 'tpcore'),
'icon' => esc_html__('Icon', 'tpcore'),
'svg' => esc_html__('SVG', 'tpcore'),
],
]
);
$repeater->add_control(
'tp_box_icon_svg',
[
'show_label' => false,
'type' => Controls_Manager::TEXTAREA,
'label_block' => true,
'placeholder' => esc_html__('SVG Code Here', 'tpcore'),
'condition' => [
'tp_box_icon_type' => 'svg',
]
]
);
$repeater->add_control(
'tp_box_icon_image',
[
'label' => esc_html__('Upload Icon Image', 'tpcore'),
'type' => Controls_Manager::MEDIA,
'default' => [
'url' => Utils::get_placeholder_image_src(),
],
'condition' => [
'tp_box_icon_type' => 'image',
]
]
);
if (tp_is_elementor_version('<', '2.6.0')) {
$repeater->add_control(
'tp_box_icon',
[
'show_label' => false,
'type' => Controls_Manager::ICON,
'label_block' => true,
'default' => 'fa fa-star',
'condition' => [
'tp_box_icon_type' => 'icon',
]
]
);
} else {
$repeater->add_control(
'tp_box_selected_icon',
[
'show_label' => false,
'type' => Controls_Manager::ICONS,
'fa4compatibility' => 'icon',
'label_block' => true,
'default' => [
'value' => 'fas fa-star',
'library' => 'solid',
],
'condition' => [
'tp_box_icon_type' => 'icon',
]
]
);
}
$repeater->add_control(
'tp_process_title', [
'label' => esc_html__('Title', 'tpcore'),
'description' => tp_get_allowed_html_desc( 'basic' ),
'type' => \Elementor\Controls_Manager::TEXT,
'default' => esc_html__('Process Title', 'tpcore'),
'label_block' => true,
]
);
$repeater->add_control(
'tp_process_des', [
'label' => esc_html__('Description', 'tpcore'),
'description' => tp_get_allowed_html_desc( 'basic' ),
'type' => \Elementor\Controls_Manager::TEXTAREA,
'default' => esc_html__('This SEO is most reputed firm', 'tpcore'),
'label_block' => true,
]
);
// creative animation
$repeater->add_control(
'tp_creative_anima_switcher',
[
'label' => esc_html__( 'Active Animation', 'tpcore' ),
'type' => \Elementor\Controls_Manager::SWITCHER,
'label_on' => esc_html__( 'Yes', 'tpcore' ),
'label_off' => esc_html__( 'No', 'tpcore' ),
'return_value' => 'yes',
'default' => '0',
'separator' => 'before',
'condition' => [
'repeater_condition' => ['style_1', 'style_7', 'style_10']
]
]
);
$repeater->add_control(
'tp_anima_type',
[
'label' => __( 'Animation Type', 'tpcore' ),
'type' => Controls_Manager::SELECT,
'options' => [
'tpfadeUp' => __( 'tpfadeUp', 'tpcore' ),
'tpfadeInDown' => __( 'tpfadeInDown', 'tpcore' ),
'tpfadeLeft' => __( 'tpfadeLeft', 'tpcore' ),
'tpfadeRight' => __( 'tpfadeRight', 'tpcore' ),
],
'default' => 'tpfadeUp',
'frontend_available' => true,
'style_transfer' => true,
'condition' => [
'tp_creative_anima_switcher' => 'yes',
'repeater_condition' => ['style_1', 'style_7', 'style_10']
],
]
);
$repeater->add_control(
'tp_anima_dura', [
'label' => esc_html__('Animation Duration', 'tpcore'),
'type' => \Elementor\Controls_Manager::TEXT,
'default' => esc_html__('0.3s', 'tpcore'),
'condition' => [
'tp_creative_anima_switcher' => 'yes',
'repeater_condition' => ['style_1', 'style_7', 'style_10']
],
]
);
$repeater->add_control(
'tp_anima_delay', [
'label' => esc_html__('Animation Delay', 'tpcore'),
'type' => \Elementor\Controls_Manager::TEXT,
'default' => esc_html__('0.6s', 'tpcore'),
'condition' => [
'tp_creative_anima_switcher' => 'yes',
'repeater_condition' => ['style_1', 'style_7', 'style_10']
],
]
);
$this->add_control(
'tp_process_list',
[
'label' => esc_html__('Processs - List', 'tpcore'),
'type' => \Elementor\Controls_Manager::REPEATER,
'fields' => $repeater->get_controls(),
'default' => [
[
'tp_process_title' => esc_html__('Discover', 'tpcore'),
],
[
'tp_process_title' => esc_html__('Define', 'tpcore')
],
[
'tp_process_title' => esc_html__('Develop', 'tpcore')
],
],
'title_field' => '{{{ tp_process_title }}}',
]
);
$this->end_controls_section();
// shape
$this->start_controls_section(
'tp_shape',
[
'label' => esc_html__( 'Shape Section', 'tpcore' ),
'condition' => [
'tp_design_style' => ['layout-1', 'layout-3']
]
]
);
$this->add_control(
'tp_shape_switch',
[
'label' => esc_html__( 'Shape On/Off', 'tpcore' ),
'type' => \Elementor\Controls_Manager::SWITCHER,
'label_on' => esc_html__( 'Show', 'tpcore' ),
'label_off' => esc_html__( 'Hide', 'tpcore' ),
'return_value' => 'yes',
'default' => '0',
]
);
$this->add_control(
'tp_shape_image_1',
[
'label' => esc_html__( 'Choose Shape Image 1', 'tpcore' ),
'type' => \Elementor\Controls_Manager::MEDIA,
'default' => [
'url' => \Elementor\Utils::get_placeholder_image_src(),
],
'condition' => [
'tp_shape_switch' => 'yes',
'tp_design_style' => 'layout-1'
]
]
);
$this->add_group_control(
Group_Control_Image_Size::get_type(),
[
'name' => 'shape_image_size', // // Usage: `{name}_size` and `{name}_custom_dimension`, in this case `thumbnail_size` and `thumbnail_custom_dimension`.
'exclude' => ['custom'],
'condition' => [
'tp_shape_switch' => 'yes',
'tp_design_style' => 'layout-1'
],
'default' => 'full'
]
);
$this->end_controls_section();
// section column
$this->tp_columns('col', ['layout-1', 'layout-3', 'layout-4', 'layout-7', 'layout-10']);
}
// style_tab_content
protected function style_tab_content(){
$this->tp_section_style_controls('process_section', 'Section', '.tp-el-section');
// rep
$this->tp_icon_style('rep_icon', 'Process List Icon/Image/SVG', '.tp-el-rep-icon', ['layout-1', 'layout-2', 'layout-3', 'layout-4', 'layout-5', 'layout-6', 'layout-7', 'layout-8', 'layout-9', 'layout-10']);
$this->tp_basic_style_controls('rep_title', 'Process List Title', '.tp-el-rep-title', ['layout-1', 'layout-2', 'layout-3', 'layout-4', 'layout-5', 'layout-6', 'layout-7', 'layout-8', 'layout-9', 'layout-10']);
$this->tp_basic_style_controls('rep_desc', 'Process List Description', '.tp-el-rep-content', ['layout-1', 'layout-2', 'layout-3', 'layout-4', 'layout-5', 'layout-6', 'layout-7', 'layout-8', 'layout-9', 'layout-10']);
}
/**
* Render the widget output on the frontend.
*
* Written in PHP and used to generate the final HTML.
*
* @since 1.0.0
*
* @access protected
*/
protected function render() {
$settings = $this->get_settings_for_display();
?>
<?php if ( $settings['tp_design_style'] == 'layout-2' ) : ?>
<div class="tp-business__item-box mb-20 tp-el-section">
<div class="row row-cols-xl-5 row-cols-lg-5 row-cols-md-3 row-cols-sm-3 row-cols-2">
<?php foreach ($settings['tp_process_list'] as $key => $item) : ?>
<div class="col mb-30">
<div class="tp-business__item text-center">
<?php if($item['tp_box_icon_type'] == 'icon') : ?>
<?php if (!empty($item['tp_box_icon']) || !empty($item['tp_box_selected_icon']['value'])) : ?>
<span class="tp-el-rep-icon">
<?php tp_render_icon($item, 'tp_box_icon', 'tp_box_selected_icon'); ?>
</span>
<?php endif; ?>
<?php elseif( $item['tp_box_icon_type'] == 'image' ) : ?>
<?php if (!empty($item['tp_box_icon_image']['url'])): ?>
<span class="tp-el-rep-icon">
<img src="<?php echo $item['tp_box_icon_image']['url']; ?>"
alt="<?php echo get_post_meta(attachment_url_to_postid($item['tp_box_icon_image']['url']), '_wp_attachment_image_alt', true); ?>">
</span>
<?php endif; ?>
<?php else : ?>
<?php if (!empty($item['tp_box_icon_svg'])): ?>
<span class="tp-el-rep-icon">
<?php echo $item['tp_box_icon_svg']; ?>
</span>
<?php endif; ?>
<?php endif; ?>
<?php if(!empty($item['tp_process_title'])) : ?>
<h5 class="tp-business__title tp-el-rep-title"><?php echo tp_kses($item['tp_process_title']); ?></h5>
<?php endif; ?>
<?php if(!empty($item['tp_process_des'])) : ?>
<p class="tp-el-rep-content"><?php echo tp_kses($item['tp_process_des']); ?></p>
<?php endif; ?>
</div>
</div>
<?php endforeach; ?>
</div>
</div>
<?php elseif ( $settings['tp_design_style'] == 'layout-3' ) : ?>
<section class="tp-el-section">
<div class="container">
<div class="tp-process-2__wrap p-relative">
<?php if(!empty($settings['tp_shape_switch'])) : ?>
<div class="tp-process-2__shape">
<span>
<svg width="882" height="120" viewBox="0 0 882 120" fill="none" xmlns="http://www.w3.org/2000/svg">
<path
d="M2.68671 18.713C78.2944 79.3767 176.059 123.624 319.883 88.7501C499.664 45.1583 648.294 -48.509 879 98.4999"
stroke="black" stroke-opacity="0.2" stroke-dasharray="3 3" />
<circle cx="248.5" cy="100.5" r="3.5" fill="#E9E9E9" />
<circle cx="677.5" cy="21.5" r="3.5" fill="#E9E9E9" />
</svg>
</span>
</div>
<?php endif; ?>
<div class="row">
<?php foreach ($settings['tp_process_list'] as $key => $item) :
$key = $key + 1;
$keyCount = count($settings['tp_process_list']);
$border = $key == $keyCount ? 'border-none' : NULL;
?>
<div
class="col-xl-<?php echo esc_attr($settings['tp_col_for_desktop']); ?> col-lg-<?php echo esc_attr($settings['tp_col_for_laptop']); ?> col-md-<?php echo esc_attr($settings['tp_col_for_tablet']); ?> col-<?php echo esc_attr($settings['tp_col_for_mobile']); ?> mb-30">
<div class="tp-process-2__item text-center">
<div class="tp-process-2__icon">
<?php if($item['tp_box_icon_type'] == 'icon') : ?>
<?php if (!empty($item['tp_box_icon']) || !empty($item['tp_box_selected_icon']['value'])) : ?>
<span class="tp-el-rep-icon">
<?php tp_render_icon($item, 'tp_box_icon', 'tp_box_selected_icon'); ?>
</span>
<?php endif; ?>
<?php elseif( $item['tp_box_icon_type'] == 'image' ) : ?>
<?php if (!empty($item['tp_box_icon_image']['url'])): ?>
<span class="tp-el-rep-icon">
<img src="<?php echo $item['tp_box_icon_image']['url']; ?>"
alt="<?php echo get_post_meta(attachment_url_to_postid($item['tp_box_icon_image']['url']), '_wp_attachment_image_alt', true); ?>">
</span>
<?php endif; ?>
<?php else : ?>
<?php if (!empty($item['tp_box_icon_svg'])): ?>
<span class="tp-el-rep-icon">
<?php echo $item['tp_box_icon_svg']; ?>
</span>
<?php endif; ?>
<?php endif; ?>
</div>
<div class="tp-process-2__text">
<?php if(!empty($item['tp_process_title'])) : ?>
<h4 class="tp-process-2__title tp-el-rep-title"><?php echo tp_kses($item['tp_process_title']); ?></h4>
<?php endif; ?>
<?php if(!empty($item['tp_process_des'])) : ?>
<p class="tp-el-rep-content"><?php echo tp_kses($item['tp_process_des']); ?></p>
<?php endif; ?>
</div>
</div>
</div>
<?php endforeach; ?>
</div>
</div>
</div>
</section>
<?php elseif ( $settings['tp_design_style'] == 'layout-4' ) : ?>
<div class="tp-feature-3__area pt-30 pb-55 tp-el-section">
<div class="tp-feature-3__plr">
<div class="container-fluid g-0">
<div class="row">
<?php foreach ($settings['tp_process_list'] as $key => $item) :
$key = $key + 1;
$keyCount = count($settings['tp_process_list']);
$border = $key == $keyCount ? 'border-none' : NULL;
?>
<div
class="col-xl-<?php echo esc_attr($settings['tp_col_for_desktop']); ?> col-lg-<?php echo esc_attr($settings['tp_col_for_laptop']); ?> col-md-<?php echo esc_attr($settings['tp_col_for_tablet']); ?> col-<?php echo esc_attr($settings['tp_col_for_mobile']); ?> pb-30">
<div
class="tp-feature-3__item item-border-<?php echo esc_attr($key); ?> feature-col-<?php echo esc_attr($key+4); ?> d-flex align-items-start">
<div class="tp-feature-3__icon">
<?php if($item['tp_box_icon_type'] == 'icon') : ?>
<?php if (!empty($item['tp_box_icon']) || !empty($item['tp_box_selected_icon']['value'])) : ?>
<span class="tp-el-rep-icon">
<?php tp_render_icon($item, 'tp_box_icon', 'tp_box_selected_icon'); ?>
</span>
<?php endif; ?>
<?php elseif( $item['tp_box_icon_type'] == 'image' ) : ?>
<?php if (!empty($item['tp_box_icon_image']['url'])): ?>
<span class="tp-el-rep-icon">
<img src="<?php echo $item['tp_box_icon_image']['url']; ?>"
alt="<?php echo get_post_meta(attachment_url_to_postid($item['tp_box_icon_image']['url']), '_wp_attachment_image_alt', true); ?>">
</span>
<?php endif; ?>
<?php else : ?>
<?php if (!empty($item['tp_box_icon_svg'])): ?>
<span class="tp-el-rep-icon">
<?php echo $item['tp_box_icon_svg']; ?>
</span>
<?php endif; ?>
<?php endif; ?>
</div>
<div class="tp-feature-3__text">
<?php if(!empty($item['tp_process_title'])) : ?>
<h5 class="tp-el-rep-title"><?php echo tp_kses($item['tp_process_title']); ?></h5>
<?php endif; ?>
<?php if(!empty($item['tp_process_des'])) : ?>
<span class="tp-el-rep-content"><?php echo tp_kses($item['tp_process_des']); ?></span>
<?php endif; ?>
</div>
</div>
</div>
<?php endforeach; ?>
</div>
</div>
</div>
</div>
<?php elseif ( $settings['tp_design_style'] == 'layout-5' ) : ?>
<div class="tp-contact-3__address-info tp-el-section">
<ul>
<?php foreach ($settings['tp_process_list'] as $key => $item) :
$key = $key + 1;
$keyCount = count($settings['tp_process_list']);
$border = $key == $keyCount ? 'border-none' : NULL;
?>
<li>
<div class="tp-contact-3__address-item">
<?php if(!empty($item['tp_process_title'])) : ?>
<h5 class="tp-el-rep-title"><?php echo tp_kses($item['tp_process_title']); ?>
<?php if($item['tp_box_icon_type'] == 'icon') : ?>
<?php if (!empty($item['tp_box_icon']) || !empty($item['tp_box_selected_icon']['value'])) : ?>
<span class="tp-el-rep-icon">
<?php tp_render_icon($item, 'tp_box_icon', 'tp_box_selected_icon'); ?>
</span>
<?php endif; ?>
<?php elseif( $item['tp_box_icon_type'] == 'image' ) : ?>
<?php if (!empty($item['tp_box_icon_image']['url'])): ?>
<span class="tp-el-rep-icon">
<img src="<?php echo $item['tp_box_icon_image']['url']; ?>"
alt="<?php echo get_post_meta(attachment_url_to_postid($item['tp_box_icon_image']['url']), '_wp_attachment_image_alt', true); ?>">
</span>
<?php endif; ?>
<?php else : ?>
<?php if (!empty($item['tp_box_icon_svg'])): ?>
<span class="tp-el-rep-icon">
<?php echo $item['tp_box_icon_svg']; ?>
</span>
<?php endif; ?>
<?php endif; ?>
</h5>
<?php endif; ?>
<?php if(!empty($item['tp_process_des'])) : ?>
<p class="tp-el-rep-content"><?php echo tp_kses($item['tp_process_des']); ?></p>
<?php endif; ?>
</div>
</li>
<?php endforeach; ?>
</ul>
</div>
<?php elseif ( $settings['tp_design_style'] == 'layout-6' ) : ?>
<div class="tp-feature-top-4__area fix pt-75 pb-40 tp-el-section">
<div class="container custom-container-3">
<div class="tp-feature-top-4__border">
<div class="row row-cols-xl-5 row-cols-lg-5 row-cols-md-3 row-cols-1 row-cols-sm-2">
<?php foreach ($settings['tp_process_list'] as $key => $item) :
$key = $key + 1;
$keyCount = count($settings['tp_process_list']);
$border = $key == $keyCount ? 'border-none' : NULL;
?>
<div class="col mb-30">
<div class="tp-feature-top-4__item text-center">
<?php if($item['tp_box_icon_type'] == 'icon') : ?>
<?php if (!empty($item['tp_box_icon']) || !empty($item['tp_box_selected_icon']['value'])) : ?>
<span class="tp-el-rep-icon">
<?php tp_render_icon($item, 'tp_box_icon', 'tp_box_selected_icon'); ?>
</span>
<?php endif; ?>
<?php elseif( $item['tp_box_icon_type'] == 'image' ) : ?>
<?php if (!empty($item['tp_box_icon_image']['url'])): ?>
<span class="tp-el-rep-icon">
<img src="<?php echo $item['tp_box_icon_image']['url']; ?>"
alt="<?php echo get_post_meta(attachment_url_to_postid($item['tp_box_icon_image']['url']), '_wp_attachment_image_alt', true); ?>">
</span>
<?php endif; ?>
<?php else : ?>
<?php if (!empty($item['tp_box_icon_svg'])): ?>
<span class="tp-el-rep-icon">
<?php echo $item['tp_box_icon_svg']; ?>
</span>
<?php endif; ?>
<?php endif; ?>
<?php if(!empty($item['tp_process_title'])) : ?>
<h5 class="tp-feature-top-4__title tp-el-rep-title"><?php echo tp_kses($item['tp_process_title']); ?></h5>
<?php endif; ?>
<?php if(!empty($item['tp_process_des'])) : ?>
<p class="tp-el-rep-content"><?php echo tp_kses($item['tp_process_des']); ?></p>
<?php endif; ?>
</div>
</div>
<?php endforeach; ?>
</div>
</div>
</div>
</div>
<?php elseif ( $settings['tp_design_style'] == 'layout-7' ) : ?>
<div class="tp-footer-4-top__area mt-70 tp-el-section">
<div class="container custom-container-3">
<div class="tp-footer-4-top__border">
<div class="row">
<?php foreach ($settings['tp_process_list'] as $key => $item) :
$key = $key + 1;
$keyCount = count($settings['tp_process_list']);
$border = $key == $keyCount ? 'border-none' : NULL;
?>
<div class="col-xl-<?php echo esc_attr($settings['tp_col_for_desktop']); ?> col-lg-<?php echo esc_attr($settings['tp_col_for_laptop']); ?> col-md-<?php echo esc_attr($settings['tp_col_for_tablet']); ?> col-<?php echo esc_attr($settings['tp_col_for_mobile']); ?> mb-30 <?php echo $item['tp_creative_anima_switcher'] ? "wow ".$item['tp_anima_type'] : NULL; ?> "
<?php echo $item['tp_creative_anima_switcher'] ? "data-wow-duration=".$item['tp_anima_dura']." "."data-wow-delay=".$item['tp_anima_delay']." " : NULL; ?>>
<div class="tp-footer-4-top__item item-border-<?php echo esc_attr($key); ?>">
<div class="tp-feature-3__item d-flex align-items-center">
<div class="tp-feature-3__icon">
<?php if($item['tp_box_icon_type'] == 'icon') : ?>
<?php if (!empty($item['tp_box_icon']) || !empty($item['tp_box_selected_icon']['value'])) : ?>
<span class="tp-el-rep-icon">
<?php tp_render_icon($item, 'tp_box_icon', 'tp_box_selected_icon'); ?>
</span>
<?php endif; ?>
<?php elseif( $item['tp_box_icon_type'] == 'image' ) : ?>
<?php if (!empty($item['tp_box_icon_image']['url'])): ?>
<span class="tp-el-rep-icon">
<img src="<?php echo $item['tp_box_icon_image']['url']; ?>"
alt="<?php echo get_post_meta(attachment_url_to_postid($item['tp_box_icon_image']['url']), '_wp_attachment_image_alt', true); ?>">
</span>
<?php endif; ?>
<?php else : ?>
<?php if (!empty($item['tp_box_icon_svg'])): ?>
<span class="tp-el-rep-icon">
<?php echo $item['tp_box_icon_svg']; ?>
</span>
<?php endif; ?>
<?php endif; ?>
</div>
<div class="tp-feature-3__text">
<?php if(!empty($item['tp_process_title'])) : ?>
<h5 class="tp-el-rep-title"><?php echo tp_kses($item['tp_process_title']); ?></h5>
<?php endif; ?>
<?php if(!empty($item['tp_process_des'])) : ?>
<span class="tp-el-rep-content"><?php echo tp_kses($item['tp_process_des']); ?></span>
<?php endif; ?>
</div>
</div>
</div>
</div>
<?php endforeach; ?>
</div>
</div>
</div>
</div>
<?php elseif ( $settings['tp_design_style'] == 'layout-8' ) : ?>
<div class="tp-feature-5__area tp-feature-5__space tp-el-section">
<div class="container custom-container-4">
<div class="tp-feature-5__border">
<div class="row row-cols-xl-5 row-cols-lg-4 row-cols-md-3 row-cols-1 row-cols-sm-2">
<?php foreach ($settings['tp_process_list'] as $key => $item) :
$key = $key + 1;
$keyCount = count($settings['tp_process_list']);
$border = $key == $keyCount ? 'border-none' : NULL;
?>
<div class="col">
<div class="tp-feature-5__item-box d-flex align-items-center">
<div class="tp-feature-3__icon">
<?php if($item['tp_box_icon_type'] == 'icon') : ?>
<?php if (!empty($item['tp_box_icon']) || !empty($item['tp_box_selected_icon']['value'])) : ?>
<span class="tp-el-rep-icon">
<?php tp_render_icon($item, 'tp_box_icon', 'tp_box_selected_icon'); ?>
</span>
<?php endif; ?>
<?php elseif( $item['tp_box_icon_type'] == 'image' ) : ?>
<?php if (!empty($item['tp_box_icon_image']['url'])): ?>
<span class="tp-el-rep-icon">
<img src="<?php echo $item['tp_box_icon_image']['url']; ?>"
alt="<?php echo get_post_meta(attachment_url_to_postid($item['tp_box_icon_image']['url']), '_wp_attachment_image_alt', true); ?>">
</span>
<?php endif; ?>
<?php else : ?>
<?php if (!empty($item['tp_box_icon_svg'])): ?>
<span class="tp-el-rep-icon">
<?php echo $item['tp_box_icon_svg']; ?>
</span>
<?php endif; ?>
<?php endif; ?>
</div>
<div class="tp-feature-3__text">
<?php if(!empty($item['tp_process_title'])) : ?>
<h5 class="tp-el-rep-title"><?php echo tp_kses($item['tp_process_title']); ?></h5>
<?php endif; ?>
<?php if(!empty($item['tp_process_des'])) : ?>
<span class="tp-el-rep-content"><?php echo tp_kses($item['tp_process_des']); ?></span>
<?php endif; ?>
</div>
</div>
</div>
<?php endforeach; ?>
</div>
</div>
</div>
</div>
<?php elseif ( $settings['tp_design_style'] == 'layout-9' ) : ?>
<div class="tp-project-process-9 tp-el-section">
<ul>
<?php foreach ($settings['tp_process_list'] as $key => $item) :
$key = $key + 1;
$keyCount = count($settings['tp_process_list']);
$border = $key == $keyCount ? 'border-none' : NULL;
?>
<li>
<div class="tp-project__details-item d-flex align-items-center">
<div class="tp-project__details-icon">
<?php if($item['tp_box_icon_type'] == 'icon') : ?>
<?php if (!empty($item['tp_box_icon']) || !empty($item['tp_box_selected_icon']['value'])) : ?>
<span class="tp-el-rep-icon">
<?php tp_render_icon($item, 'tp_box_icon', 'tp_box_selected_icon'); ?>
</span>
<?php endif; ?>
<?php elseif( $item['tp_box_icon_type'] == 'image' ) : ?>
<?php if (!empty($item['tp_box_icon_image']['url'])): ?>
<span class="tp-el-rep-icon">
<img src="<?php echo $item['tp_box_icon_image']['url']; ?>"
alt="<?php echo get_post_meta(attachment_url_to_postid($item['tp_box_icon_image']['url']), '_wp_attachment_image_alt', true); ?>">
</span>
<?php endif; ?>
<?php else : ?>
<?php if (!empty($item['tp_box_icon_svg'])): ?>
<span class="tp-el-rep-icon">
<?php echo $item['tp_box_icon_svg']; ?>
</span>
<?php endif; ?>
<?php endif; ?>
</div>
<div class="tp-project__details-text">
<?php if(!empty($item['tp_process_title'])) : ?>
<h6 class="tp-el-rep-title"><?php echo tp_kses($item['tp_process_title']); ?></h6>
<?php endif; ?>
<?php if(!empty($item['tp_process_des'])) : ?>
<span class="tp-el-rep-content"><?php echo tp_kses($item['tp_process_des']); ?></span>
<?php endif; ?>
</div>
</div>
</li>
<?php endforeach; ?>
</ul>
</div>
<?php elseif ( $settings['tp_design_style'] == 'layout-10' ) : ?>
<div class="tp-choose-6__area pt-10 pb-40 tp-el-section">
<div class="container">
<div class="row">
<?php foreach ($settings['tp_process_list'] as $key => $item) :
$key = $key + 1;
$keyCount = count($settings['tp_process_list']);
$border = $key == $keyCount ? 'border-none' : NULL;
?>
<div class="col-xl-<?php echo esc_attr($settings['tp_col_for_desktop']); ?> col-lg-<?php echo esc_attr($settings['tp_col_for_laptop']); ?> col-md-<?php echo esc_attr($settings['tp_col_for_tablet']); ?> col-<?php echo esc_attr($settings['tp_col_for_mobile']); ?> mb-30 <?php echo $item['tp_creative_anima_switcher'] ? "wow ".$item['tp_anima_type'] : NULL; ?> "
<?php echo $item['tp_creative_anima_switcher'] ? "data-wow-duration=".$item['tp_anima_dura']." "."data-wow-delay=".$item['tp_anima_delay']." " : NULL; ?>>
<div class="tp-choose-6__item-wrap <?php echo $key%2==0 ? 'space' : NULL; ?>">
<div class="tp-choose-6__item">
<div class="tp-choose-6__icon">
<?php if($item['tp_box_icon_type'] == 'icon') : ?>
<?php if (!empty($item['tp_box_icon']) || !empty($item['tp_box_selected_icon']['value'])) : ?>
<span class="tp-el-rep-icon">
<?php tp_render_icon($item, 'tp_box_icon', 'tp_box_selected_icon'); ?>
</span>
<?php endif; ?>
<?php elseif( $item['tp_box_icon_type'] == 'image' ) : ?>
<?php if (!empty($item['tp_box_icon_image']['url'])): ?>
<span class="tp-el-rep-icon">
<img src="<?php echo $item['tp_box_icon_image']['url']; ?>"
alt="<?php echo get_post_meta(attachment_url_to_postid($item['tp_box_icon_image']['url']), '_wp_attachment_image_alt', true); ?>">
</span>
<?php endif; ?>
<?php else : ?>
<?php if (!empty($item['tp_box_icon_svg'])): ?>
<span class="tp-el-rep-icon">
<?php echo $item['tp_box_icon_svg']; ?>
</span>
<?php endif; ?>
<?php endif; ?>
</div>
<div class="tp-choose-6__content">
<?php if(!empty($item['tp_process_title'])) : ?>
<h4 class="tp-choose-6__title tp-el-rep-title"><?php echo tp_kses($item['tp_process_title']); ?></h4>
<?php endif; ?>
<?php if(!empty($item['tp_process_des'])) : ?>
<p class="tp-el-rep-content"><?php echo tp_kses($item['tp_process_des']); ?></p>
<?php endif; ?>
</div>
</div>
</div>
</div>
<?php endforeach; ?>
</div>
</div>
</div>
<?php else:
// shape image
if ( !empty($settings['tp_shape_image_1']['url']) ) {
$tp_shape_image = !empty($settings['tp_shape_image_1']['id']) ? wp_get_attachment_image_url( $settings['tp_shape_image_1']['id'], $settings['shape_image_size_size']) : $settings['tp_shape_image_1']['url'];
$tp_shape_image_alt = get_post_meta($settings["tp_shape_image_1"]["id"], "_wp_attachment_image_alt", true);
}
?>
<div class="tp-feature__area p-relative tp-el-section">
<?php if(!empty($tp_shape_image)) : ?>
<div class="tp-feature__shape-1 d-none d-xl-block">
<img src="<?php echo esc_url($tp_shape_image); ?>" alt="<?php echo esc_attr($tp_shape_image_alt); ?>">
</div>
<?php endif; ?>
<div class="container">
<div class="tp-feature__border">
<div class="row">
<?php foreach ($settings['tp_process_list'] as $key => $item) :
$key = $key + 1;
$keyCount = count($settings['tp_process_list']);
$border = $key == $keyCount ? 'border-none' : NULL;
?>
<div class="col-xl-<?php echo esc_attr($settings['tp_col_for_desktop']); ?> col-lg-<?php echo esc_attr($settings['tp_col_for_laptop']); ?> col-md-<?php echo esc_attr($settings['tp_col_for_tablet']); ?> col-<?php echo esc_attr($settings['tp_col_for_mobile']); ?> mb-30 <?php echo $item['tp_creative_anima_switcher'] ? "wow ".$item['tp_anima_type'] : NULL; ?> "
<?php echo $item['tp_creative_anima_switcher'] ? "data-wow-duration=".$item['tp_anima_dura']." "."data-wow-delay=".$item['tp_anima_delay']." " : NULL; ?>>
<div
class="tp-feature__item feature-col-<?php echo esc_attr($key); ?> d-flex align-items-center <?php echo esc_attr($border); ?>">
<div class="tp-feature__icon">
<?php if($item['tp_box_icon_type'] == 'icon') : ?>
<?php if (!empty($item['tp_box_icon']) || !empty($item['tp_box_selected_icon']['value'])) : ?>
<span class="tp-el-rep-icon">
<?php tp_render_icon($item, 'tp_box_icon', 'tp_box_selected_icon'); ?>
</span>
<?php endif; ?>
<?php elseif( $item['tp_box_icon_type'] == 'image' ) : ?>
<?php if (!empty($item['tp_box_icon_image']['url'])): ?>
<span class="tp-el-rep-icon">
<img src="<?php echo $item['tp_box_icon_image']['url']; ?>"
alt="<?php echo get_post_meta(attachment_url_to_postid($item['tp_box_icon_image']['url']), '_wp_attachment_image_alt', true); ?>">
</span>
<?php endif; ?>
<?php else : ?>
<?php if (!empty($item['tp_box_icon_svg'])): ?>
<span class="tp-el-rep-icon">
<?php echo $item['tp_box_icon_svg']; ?>
</span>
<?php endif; ?>
<?php endif; ?>
</div>
<div class="tp-feature__content">
<?php if(!empty($item['tp_process_title'])) : ?>
<h4 class="tp-feature__title tp-el-rep-title"><?php echo tp_kses($item['tp_process_title']); ?></h4>
<?php endif; ?>
<?php if(!empty($item['tp_process_des'])) : ?>
<p class="tp-el-rep-content"><?php echo tp_kses($item['tp_process_des']); ?></p>
<?php endif; ?>
</div>
</div>
</div>
<?php endforeach; ?>
</div>
</div>
</div>
</div>
<?php endif;
}
}
$widgets_manager->register( new TP_Process() );