<?php 

add_action('dslc_hook_register_modules',
     create_function('', 'return dslc_register_module( "Ainex_Support" );')
);

class Ainex_Support extends DSLC_Module {
 		
 	// Module Attributes
    var $module_id = 'Ainex_Support';
    var $module_title = 'Support';
    var $module_icon = 'font';
    var $module_category = 'Ainex - Blocks';
 
 	// Module Options
    function options() { 
    	// The options array
    	$dslc_options = array(
			array(
				'label' => __('Support - Title', 'themestudio'),
				'id' => 'title',
				'std' => 'Support',
				'type' => 'text',
				'section' => 'functionality',
			),
			array(
				'label' => __('Text Contact', 'themestudio'),
				'id' => 'phone',
				'std' => '<p>Lorem Ipsum is simply dummy text of the printing and typesetting industry.</p><p><strong>US customers: 1-234-4567-89000</strong><strong>International customers: +1-234-4567-89000 </strong></p>',
				'type' => 'textarea',
				'section' => 'functionality',
			),
			array(
				'label' => __('Email Contact', 'themestudio'),
				'id' => 'email',
				'std' => 'salesyourcompany@name.com',
				'type' => 'text',
				'section' => 'functionality',
			),
			array(
				'label' => __('Time Contact', 'themestudio'),
				'id' => 'time',
				'std' => "24/7 - excluding national holidays.",
				'type' => 'textarea',
				'section' => 'functionality',
			),
			array(
				'label' => __( 'Margin Bottom', 'dslc_string' ),
				'id' => 'css_margin_bottom',
				'std' => '0',
				'type' => 'slider',
				'refresh_on_change' => false,
				'affect_on_change_el' => '.our_support_main',
				'affect_on_change_rule' => 'margin-bottom',
				'section' => 'styling',
				'ext' => 'px',
			),
		);
		$dslc_options = array_merge( $dslc_options, $this->shared_options('animation_options') );

    	// Return the array
    	return apply_filters( 'dslc_module_options', $dslc_options, $this->module_id );

    }
 
 	// Module Output
    function output( $options ) {

    	global $dslc_active;
    	
		if ( $dslc_active && is_user_logged_in() && current_user_can( DS_LIVE_COMPOSER_CAPABILITY ) )
			$dslc_is_admin = true;
		else
			$dslc_is_admin = false;
		
		//REQUIRED
		$this->module_start( $options );
	?>
		<div class="our_support_main">
			<div class="our_support_help">
	        	<h3><?php echo $options['title']; ?></h3>
	            <h5><i class="fa fa-headphones fa-lg"></i>&nbsp; Phone</h5> 
	            <?php echo $options['phone']; ?>
	            <h5><i class="fa fa-envelope fa-lg"></i>&nbsp; E-mail</h5>  
	            <p><strong><a href="mailto:<?php echo $options['email']; ?>"><?php echo $options['email']; ?></a></strong></p>
	            <h5><i class="fa fa-clock-o fa-lg"></i>&nbsp; Hours</h5>  
	            <p><strong><?php echo $options['time']; ?></strong></p>
	        </div>
		</div>
		<div class="clearfix"></div>

	<?php
    	// REQUIRED
    	$this->module_end( $options );

    }
 
}