<?php
////////////////////// CORE FUNCTION | MODULE FUNCTION (c) i2d Technologies //////////////////////////////////
if (!function_exists('include_css')) {
function include_css() { 

$css_files=array(
'plugins/datatables/jquery.dataTables.min.css',
'plugins/datatables/buttons.bootstrap.min.css',
'plugins/datatables/responsive.bootstrap.min.css',
'plugins/datatables/scroller.bootstrap.min.css',
'plugins/datatables/dataTables.colVis.css',
'plugins/datatables/dataTables.bootstrap.min.css',
'plugins/datatables/fixedColumns.dataTables.min.css',
'plugins/morris/morris.css',
'css/bootstrap.min.css',
'css/metisMenu.min.css',
'css/icons.css','css/style.css',
'plugins/bootstrap-tagsinput/css/bootstrap-tagsinput.css',
'plugins/select2/css/select2.min.css',
'plugins/bootstrap-colorpicker/css/bootstrap-colorpicker.min.css',
'plugins/bootstrap-datepicker/css/bootstrap-datepicker.min.css',
'plugins/bootstrap-daterangepicker/daterangepicker.css',
'plugins/timepicker/bootstrap-timepicker.min.css',
'plugins/dropify/css/dropify.min.css',
'plugins/summernote2/sum.css',

);


    foreach ($css_files as $item){
		?>
        <link href="<?php echo admin_base.$item; ?>" rel="stylesheet"">
		<?php 
		}
} 
}
/////////////////////////// function ends /////////////////////////////////
////////////////////// CORE FUNCTION | MODULE FUNCTION (c) i2d Technologies //////////////////////////////////
if (!function_exists('include_css_blog')) {
function include_css_blog() { 

$css_files=array(
'plugins/datatables/jquery.dataTables.min.css',
'plugins/datatables/buttons.bootstrap.min.css',
'plugins/datatables/responsive.bootstrap.min.css',
'plugins/datatables/scroller.bootstrap.min.css',
'plugins/datatables/dataTables.colVis.css',
'plugins/datatables/dataTables.bootstrap.min.css',
'plugins/datatables/fixedColumns.dataTables.min.css',
'plugins/morris/morris.css',
'css/bootstrap.min.css',
'css/metisMenu.min.css',
'css/icons.css','css/style_2.css',
'plugins/bootstrap-tagsinput/css/bootstrap-tagsinput.css',
'plugins/select2/css/select2.min.css',
'plugins/bootstrap-colorpicker/css/bootstrap-colorpicker.min.css',
'plugins/bootstrap-datepicker/css/bootstrap-datepicker.min.css',
'plugins/bootstrap-daterangepicker/daterangepicker.css',
'plugins/timepicker/bootstrap-timepicker.min.css',
'plugins/dropify/css/dropify.min.css',
'plugins/summernote2/sum.css',

);


    foreach ($css_files as $item){
		?>
        <link href="<?php echo admin_base.$item; ?>" rel="stylesheet"">
		<?php 
		}
} 
}
/////////////////////////// function ends /////////////////////////////////
////////////////////// CORE FUNCTION | MODULE FUNCTION (c) i2d Technologies //////////////////////////////////
if (!function_exists('include_scripts')) {
function include_scripts() { 

$script_files=array(
		'js/bootstrap.min.js',
		'js/metisMenu.min.js',
		'plugins/datatables/jquery.dataTables.min.js',
		'plugins/datatables/dataTables.bootstrap.js',
		'plugins/datatables/dataTables.buttons.min.js',
		'plugins/datatables/buttons.bootstrap.min.js',
		'plugins/datatables/dataTables.keyTable.min.js',
        'plugins/datatables/dataTables.responsive.min.js',
        'plugins/datatables/responsive.bootstrap.min.js',
        'plugins/datatables/buttons.html5.min.js',
        'plugins/datatables/pdfmake.min.js',
        'plugins/datatables/buttons.print.min.js',
        'plugins/datatables/jszip.min.js',
        'plugins/datatables/vfs_fonts.js',
        'plugins/datatables/buttons.html5.min.js',
        'plugins/datatables/dataTables.scroller.min.js',
        'plugins/datatables/dataTables.colVis.js',
        'plugins/datatables/dataTables.fixedColumns.min.js',
        
		//'pages/jquery.datatables.init.js',
		'js/jquery.slimscroll.min.js',
		'plugins/morris/morris.min.js',
		'plugins/bootstrap-tagsinput/js/bootstrap-tagsinput.min.js',
		'plugins/select2/js/select2.min.js',
		'plugins/moment/moment.js',
		'plugins/timepicker/bootstrap-timepicker.js',
		'plugins/bootstrap-datepicker/js/bootstrap-datepicker.min.js',
		'plugins/clockpicker/js/bootstrap-clockpicker.min.js',
		'plugins/bootstrap-colorpicker/js/bootstrap-colorpicker.min.js',
		'plugins/bootstrap-daterangepicker/daterangepicker.js',
		'plugins/jquery-searchable/jquery.searchable.js',
		'plugins/mask/jquery.inputmask.bundle.js',
		'plugins/mask/jquery.inputmask.binding.js',
		'plugins/summernote2/sum.js',
		'pages/jquery.form-advanced.init2.js',
		'plugins/dropify/js/dropify.min.js',
		'plugins/jquery-knob/jquery.knob.js',
		'js/jquery.app.js'		
		);
		

    foreach ($script_files as $item){
		?>
		<script src="<?php echo admin_base.$item; ?>" type="text/javascript"></script>
        <?php 
		}
} 
}
/////////////////////////// function ends /////////////////////////////////
////////////////////// CORE FUNCTION | MODULE FUNCTION (c) i2d Technologies //////////////////////////////////
if (!function_exists('include_scripts_blog')) {
function include_scripts_blog() { 

$script_files=array(
		'js/bootstrap.min.js',
		'js/metisMenu.min.js',
		'plugins/datatables/jquery.dataTables.min.js',
		'plugins/datatables/dataTables.bootstrap.js',
		'plugins/datatables/dataTables.buttons.min.js',
		'plugins/datatables/buttons.bootstrap.min.js',
		'plugins/datatables/dataTables.keyTable.min.js',
        'plugins/datatables/dataTables.responsive.min.js',
        'plugins/datatables/responsive.bootstrap.min.js',
        'plugins/datatables/buttons.html5.min.js',
        'plugins/datatables/pdfmake.min.js',
        'plugins/datatables/buttons.print.min.js',
        'plugins/datatables/jszip.min.js',
        'plugins/datatables/vfs_fonts.js',
        'plugins/datatables/buttons.html5.min.js',
        'plugins/datatables/dataTables.scroller.min.js',
        'plugins/datatables/dataTables.colVis.js',
        'plugins/datatables/dataTables.fixedColumns.min.js',
        
		//'pages/jquery.datatables.init.js',
		'js/jquery.slimscroll.min.js',
		'plugins/morris/morris.min.js',
		'plugins/bootstrap-tagsinput/js/bootstrap-tagsinput.min.js',
		'plugins/select2/js/select2.min.js',
		'plugins/moment/moment.js',
		'plugins/timepicker/bootstrap-timepicker.js',
		'plugins/bootstrap-datepicker/js/bootstrap-datepicker.min.js',
		'plugins/clockpicker/js/bootstrap-clockpicker.min.js',
		'plugins/bootstrap-colorpicker/js/bootstrap-colorpicker.min.js',
		'plugins/bootstrap-daterangepicker/daterangepicker.js',
		'plugins/jquery-searchable/jquery.searchable.js',
		'plugins/mask/jquery.inputmask.bundle.js',
		'plugins/mask/jquery.inputmask.binding.js',
		'plugins/summernote2/sum.js',
		'pages/jquery.form-advanced.init2.js',
		'plugins/dropify/js/dropify.min.js',
		'plugins/jquery-knob/jquery.knob.js',
		'js/blog/jquery.app.js'		
		);
		

    foreach ($script_files as $item){
		?>
		<script src="<?php echo admin_base.$item; ?>" type="text/javascript"></script>
        <?php 
		}
} 
}
/////////////////////////// function ends /////////////////////////////////

////////////////////// CORE FUNCTION | MODULE FUNCTION (c) i2d Technologies //////////////////////////////////
if (!function_exists('include_files')) {
function include_files($files_array,$r,$t) { 

if(!empty($files_array) && isset($files_array)){
foreach ($files_array as $item){	
    include_load($item,$r,$t);
}

	}
else{
echo "i2d Website Engine v3.0 : WARNING : No Files Added For Inclusion!";	
}	
} 
}
/////////////////////////// function ends /////////////////////////////////

function i2d_secured_input($input){


$link=uplink();
$trimed=trim(strip_tags(addslashes($input)));

 $sec_content=mysqli_real_escape_string($link,$trimed);

return $sec_content;

}

/////////////////////////// function ends /////////////////////////////////

////////////////////// CORE FUNCTION | MODULE FUNCTION (c) i2d Technologies //////////////////////////////////
////////////////////// CORE FUNCTION | MODULE FUNCTION (c) i2d Technologies //////////////////////////////////
if (!function_exists('consoler')) {
function consoler($error) { 

    //$output = $data;
   // if ( is_array( $output ) )
      //  $output = implode( ',', $output);

    echo "<script>console.log( 'i2d Technologies - Website Engine (c)2015-|".$error."|);</script>";
}

} 
/////////////////////////// function ends /////////////////////////////////
////////////////////// CORE FUNCTION | MODULE FUNCTION (c) i2d Technologies //////////////////////////////////
if (!function_exists('helloworld')) {
function helloworld($var,$caption=0,$javascript=0) { 



if($caption!==0){
$string="<pre><strong>".$caption."</strong> is <strong>: ".$var."</strong> ";
}
else{
$string="<pre> Variable is <strong>: ".$var."</strong> ";	
}
   $file=basename(__FILE__, '.php');
   $file=$_SERVER["SCRIPT_FILENAME"];
   //$file=$file_name;
   $line=__LINE__;
   //$complete=$string."<pre><strong>placed in : </strong>".$file." &line is ".$line."</pre><br />";
  
  
   $complete=$string."placed in : ".$file." on ".$line." - i2d Web Engine v2.3</pre> ";
   
//echo $complete;
admin_alerts($complete);	
} 
}
/////////////////////////// function ends /////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////////
function remove_chars($str){
	
	$str=preg_replace('!\s+!', ' ', $str);

	//$str = str_replace(' ', '', $str);
	//$str = trim(preg_replace('/\s+/',' ', $str));
	//$str = str_replace(' ','-',$str);
	$str2 = str_replace("`","",$str);
	$str3 = str_replace("!","",$str2);
	$str3 = str_replace("(","",$str3);
	$str3 = str_replace(")","",$str3);
	$str4 = str_replace("%","-Percent",$str3);
	$str5 = str_replace("#","-No-",$str4);


return $str5;

}

/////////////////////////// function ends /////////////////////////////////





?>
