<?php

# Define the Logaholic software version number
define("LOGAHOLIC_VERSION_NUMBER", "8.0.0");

# PHPLOCKITOPT START
# set up an array of possible editions
$edition[0] = "Self Hosted Edition"; //"Free Edition"; # Free / Basic 
$edition[1] = "Self Hosted Edition"; # Advanced
$edition[2] = "Service Provider Edition"; # Advanced
$edition[3] = "Windows Desktop Edition"; # Depricated
$edition[4] = "cPanel Edition"; # Basic
$edition[5] = "Enterprise Edition"; # Enterprise
$edition[6] = "Advanced Edition"; # Advanced
$edition[7] = "Self Hosted Edition"; //"Basic Edition"; # Basic
$edition[8] = "Pro Edition"; # All reports

# what is this version intended to be ? (Needed to know so we can make trail version for the right edition)
define("LOGAHOLIC_BASE_EDITION", $edition[1]); // or SPE or WDE or CPA

# Is this an oficial release ? Enter release or dev  
define("LOGAHOLIC_VERSION_STATUS","release");
ini_set('display_errors', 'off');

# What method does the datafile storage use? Enter phar or gzip
$phpver = (int)str_replace(".", "", phpversion());
$phpver = substr($phpver,0,3);

$stream_wrappers = stream_get_wrappers();

if($phpver < 530) {
	$df_method = "gzip"; 	

} else if (!class_exists('ZipArchive')) { # Do we have zip archive class ?
	$df_method = "gzip"; 

} else if(!in_array("zip", $stream_wrappers) ){ # Is zip a Registered PHP Streams ?
	$df_method = "gzip";

} else {
	$df_method = "ziparchive";
}

define("DATAFILE_METHOD", $df_method);

# What database version numbers do we need?
define("CURRENT_DB_VERSION", 2.48);
define("MINIMUM_DB_VERSION", 2.48);
define("CURRENT_PROFILE_STRUCTURE_VERSION", 4.94);
define("USER_DB_VERSION", 2.21);

if(isset($_SERVER["HTTPS"]) && $_SERVER["HTTPS"] == "on"){
	$http = "https";
} else {
	$http = "http";
}

define("LOGAHOLIC_INFO_URL", "{$http}://software.logaholic.com/insoftware_info/info.php");
define("CPANEL_INFO_URL", "{$http}://software.logaholic.com/insoftware_info/cpanel.php");
?>
