HEX
Server: Apache
System: Linux scp1.abinfocom.com 5.4.0-216-generic #236-Ubuntu SMP Fri Apr 11 19:53:21 UTC 2025 x86_64
User: confeduphaar (1010)
PHP: 8.1.33
Disabled: exec,passthru,shell_exec,system
Upload Files
File: /home/confeduphaar/www/wp-content/plugins/ova-framework/ova-elementor/widgets/ova_box_contact.php
<?php

namespace ova_framework\Widgets;

use Elementor\Widget_Base;
use Elementor\Controls_Manager;
use Elementor\Core\Schemes\Typography;
use Elementor\Group_Control_Typography;
use Elementor\Core\Schemes\Color;


if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly

class ova_box_contact extends Widget_Base {

	public function get_name() {
		return 'ova_box_contact';
	}

	public function get_title() {
		return __( 'Box Contact', 'ova-framework' );
	}

	public function get_icon() {
		return 'eicon-info-circle';
	}

	public function get_categories() {
		return [ 'ovatheme' ];
	}

	public function get_script_depends() {
		return [ 'script-elementor' ];
	}

	protected function register_controls() {


		$this->start_controls_section(
			'section_heading_content',
			[
				'label' => __( 'Content', 'ova-framework' ),
				
			]
		);

		$this->add_control(
			'title',
			[
				'label' => __( 'Title', 'ova-framework' ),
				'type' => \Elementor\Controls_Manager::TEXT,
				'default' => __('Do you have request?Call or visit us.', 'ova-framework'),
			]
		);

		$this->add_control(
			'text_phone',
			[
				'label' => __( 'Text Phone', 'ova-framework' ),
				'type' => \Elementor\Controls_Manager::TEXT,
				'default' => __('Call: (807) 3500-7400', 'ova-framework'),
			]
		);

		$this->add_control(
			'phone',
			[
				'label' => __( 'Phone', 'ova-framework' ),
				'type' => \Elementor\Controls_Manager::TEXT,
				'default' => __('80735007400', 'ova-framework'),
			]
		);

		$this->add_control(
			'text_phone2',
			[
				'label' => __( 'Text Phone 2', 'ova-framework' ),
				'type' => \Elementor\Controls_Manager::TEXT,
			]
		);

		$this->add_control(
			'phone2',
			[
				'label' => __( 'Phone 2', 'ova-framework' ),
				'type' => \Elementor\Controls_Manager::TEXT,
			]
		);

		$this->add_control(
			'title_address',
			[
				'label' => __( 'Title Address', 'ova-framework' ),
				'type' => \Elementor\Controls_Manager::TEXT,
				'default' => __('City Council:', 'ova-framework'),
			]
		);

		$this->add_control(
			'address',
			[
				'label' => __( 'Address', 'ova-framework' ),
				'type' => \Elementor\Controls_Manager::TEXT,
				'default' => __('95 FF3, App Street Avenue NSW 96209, Canada', 'ova-framework'),
			]
		);

		$this->add_control(
			'title_time',
			[
				'label' => __( 'Title Time', 'ova-framework' ),
				'type' => \Elementor\Controls_Manager::TEXT,
				'default' => __('Opening Hours:', 'ova-framework'),
			]
		);

		$this->add_control(
			'time',
			[
				'label' => __( 'Time open', 'ova-framework' ),
				'type' => \Elementor\Controls_Manager::TEXT,
				'default' => __('Mon – Fri: 8:00 am – 6:00 pm', 'ova-framework'),
			]
		);


		$this->end_controls_section();

	}

	protected function render() {
		$settings = $this->get_settings();

		$title = $settings['title'];
		$text_phone = $settings['text_phone'];
		$phone = $settings['phone'];
		$text_phone2 = $settings['text_phone2'];
		$phone2 = $settings['phone2'];

		$title_address = $settings['title_address'];
		$address = $settings['address'];

		$title_time = $settings['title_time'];
		$time = $settings['time'];

		
		?>
		<div class="ova_box_contact ">
			<?php if( $title ) { ?>
				<h3 class="title">
					<?php echo $title; ?>
				</h3>
			<?php } ?>

			<?php if( $text_phone ) { ?>
				<div class="phone">
					<a href="tel:<?php echo esc_attr( $phone ); ?>" class="second_font">
						<?php echo $text_phone; ?>
					</a>
				</div>
				<?php if ( $text_phone2 ): ?>
					<div class="phone">
						<a href="tel:<?php echo esc_attr( $phone2 ) ?>" class="second_font">
							<?php echo $text_phone2; ?>
						</a>
					</div>
				<?php endif; ?>
			<?php } ?>
			<div class="wrap-address">
				<p class="title-address title-general">
					<?php echo $title_address; ?>
				</p>
				<p class="address content-general">
					<?php echo $address; ?>
				</p>
			</div>

			<div class="wrap-time">
				<p class="title-time title-general">
					<?php echo $title_time; ?>
				</p>
				<p class="time content-general">
					<?php echo $time; ?>
				</p>
			</div>

		</div>
		<?php

	}
// end render
}