This commit is contained in:
MacWarrior 2016-11-06 18:43:01 +01:00
commit 1c8be85906
2 changed files with 22 additions and 2 deletions

View file

@ -40,7 +40,7 @@ switch($mode)
$vid = $Upload->submit_upload($vidDetails);
// sending curl request to content .ok
/*// sending curl request to content .ok
$call_bk = PLUG_URL."/cb_multiserver/api/call_back.php";
$ch = curl_init($call_bk);
$ch_opts = array(
@ -60,7 +60,7 @@ switch($mode)
curl_setopt_array($ch,$charray);
curl_exec($ch);
curl_close($ch);
curl_close($ch);*/
// inserting into video views as well
$query = "INSERT INTO " . tbl("video_views") . " (video_id, video_views, last_updated) VALUES({$vid}, 0, " . time() . ")";

View file

@ -5766,6 +5766,26 @@
return $date->getTimestamp();
}
/**
* Check if a plugin is installe, active and has main file
* @param : { string } { $mainFile } { File to run check against }
* @author : Saqib Razzaq
* @since : 4th November, 2016
*
* @return : { boolean } { true or false matching pattern }
*/
function gotPlugin($mainFile) {
global $db;
$installCheck = $db->select(tbl('plugins'),'plugin_folder,plugin_active',"plugin_file = '$mainFile'");
$pluginFolder = $installCheck[0]['plugin_folder'];
$pluginStatus = $installCheck[0]['plugin_active'];
if (!empty($pluginFolder) && $pluginStatus != 'no') {
return file_exists(PLUG_DIR.'/'.$pluginFolder.'/'.$mainFile);
}
}
include( 'functions_db.php' );
include( 'functions_filter.php' );