script_version()); } else { return null; } } function check_for_wizard_update($echo_message = false) { $latest_version = latest_version(); $update_available = update_is_available($latest_version); if ($update_available) { if ($echo_message) { echo '
An updated version of this Wizard script is available here.
'; } return $latest_version; } else { return $update_available; } } function php_version() { $v = explode('.',PHP_VERSION); return array( 'major' => $v[0], 'minor' => $v[1], 'release' => $v[2]); } function is_supported_php_version() { $v = php_version(); return ((($v['major'] == 4) && ($v['minor'] >= 1)) || (($v['major'] == 5) && (($v['minor'] >= 1) || ($v['release'] >= 5)))); } function is_php_version_or_greater($major,$minor,$release = 0) { $version = php_version(); return ($version['major'] > $major || ($version['major'] == $major && $version['minor'] > $minor) || ($version['major'] == $major && $version['minor'] == $minor && $version['release'] >= $release)); } function ini_file_name() { $sysinfo = get_sysinfo(); return (!empty($sysinfo['PHP_INI'])?$sysinfo['PHP_INI_BASENAME']:'php.ini'); } function default_platform_list() { $platforms = array(); $platforms[] = array('os'=>'win', 'os_human'=>'Windows', 'arch'=>'x86', 'dirname'=>'win32', 'us1-dir'=>'windows/x86' ); $platforms[] = array('os'=>'win', 'os_human'=>'Windows (Non-TS)', 'os_mod' => '_nonts', 'arch'=>'x86', 'dirname'=>'win32-nonts', 'us1-dir'=>'windows/x86-nonts' ); $platforms[] = array('os'=>'lin', 'os_human'=>'Linux', 'arch'=>'x86', 'dirname'=>'linux_i686-glibc2.1.3', 'us1-dir'=>'linux/x86'); $platforms[] = array('os'=>'lin', 'os_human'=>'Linux', 'arch'=>'x86-64', 'dirname'=>'linux_x86_64-glibc2.3.4', 'us1-dir'=>'linux/x86_64'); $platforms[] = array('os'=>'lin','os_human'=>'Linux', 'arch'=>'ppc', 'dirname'=>'linux_ppc-glibc2.3.4','us1-dir'=>'linux/ppc'); $platforms[] = array('os'=>'lin','os_human'=>'Linux', 'arch'=>'ppc64', 'dirname'=>'linux_ppc64-glibc2.5','us1-dir'=>'linux/ppc64'); $platforms[] = array('os'=>'dra', 'os_human'=>'DragonFly', 'arch'=>'x86', 'dirname'=>'dragonfly_i386-1.7', 'us1-dir'=>'Dragonfly/x86'); $platforms[] = array('os'=>'fre', 'os_human'=>'FreeBSD 4', 'os_mod'=>'_4', 'arch'=>'x86', 'dirname'=>'freebsd_i386-4.8', 'us1-dir'=>'FreeBSD/v4'); $platforms[] = array('os'=>'fre', 'os_human'=>'FreeBSD 6', 'os_mod'=>'_6', 'arch'=>'x86', 'dirname'=>'freebsd_i386-6.2', 'us1-dir'=>'FreeBSD/v6/x86'); $platforms[] = array('os'=>'fre', 'os_human'=>'FreeBSD 6', 'os_mod'=>'_6', 'arch'=>'x86-64', 'dirname'=>'freebsd_amd64-6.1', 'us1-dir'=>'FreeBSD/v6/AMD64'); $platforms[] = array('os'=>'fre', 'os_human'=>'FreeBSD 7', 'os_mod'=>'_7', 'arch'=>'x86', 'dirname'=>'freebsd_i386-7.1', 'us1-dir'=>'FreeBSD/v7/x86'); $platforms[] = array('os'=>'fre', 'os_human'=>'FreeBSD 7', 'os_mod'=>'_7', 'arch'=>'x86-64', 'dirname'=>'freebsd_amd64-7.0', 'us1-dir'=>'FreeBSD/v7/AMD64'); $platforms[] = array('os'=>'fre', 'os_human'=>'FreeBSD 8', 'os_mod'=>'_8', 'arch'=>'x86', 'dirname'=>'freebsd_i386-8.0', 'us1-dir'=>'FreeBSD/v8/x86'); $platforms[] = array('os'=>'bsd', 'os_human'=>'BSDi', 'arch'=>'x86', 'dirname'=>'bsdi_i386-4.3.1'); $platforms[] = array('os'=>'bsd', 'os_human'=>'BSDi', 'arch'=>'x86', 'dirname'=>'bsdi_i386-4.3.1'); $platforms[] = array('os'=>'net', 'os_human'=>'NetBSD', 'arch'=>'x86', 'dirname'=>'netbsd_i386-2.1','us1-dir'=>'NetBSD/x86'); $platforms[] = array('os'=>'net', 'os_human'=>'NetBSD', 'arch'=>'x86-64', 'dirname'=>'netbsd_amd64-2.0','us1-dir'=>'NetBSD/x86_64'); $platforms[] = array('os'=>'ope', 'os_human'=>'OpenBSD 3.7', 'os_mod'=>'_3.7', 'arch'=>'x86-64', 'dirname'=>'openbsd_amd64-3.7'); $platforms[] = array('os'=>'ope', 'os_human'=>'OpenBSD 3.9', 'os_mod'=>'_3.9', 'arch'=>'x86-64', 'dirname'=>'openbsd_amd64-3.9'); $platforms[] = array('os'=>'ope', 'os_human'=>'OpenBSD 3.8', 'arch'=>'x86', 'dirname'=>'openbsd_i386-3.8', 'os_mod'=>'_3.8', 'us1-dir'=>'OpenBSD'); $platforms[] = array('os'=>'ope', 'os_human'=>'OpenBSD 4.2', 'arch'=>'x86', 'dirname'=>'openbsd_i386-4.2', 'os_mod'=>'_4.2', 'us1-dir'=>'OpenBSD'); $platforms[] = array('os'=>'ope', 'os_human'=>'OpenBSD 4.5', 'arch'=>'x86', 'dirname'=>'openbsd_i386-4.5', 'os_mod'=>'_4.5', 'us1-dir'=>'OpenBSD'); $platforms[] = array('os'=>'dar', 'os_human'=>'OS X', 'arch'=>'ppc', 'dirname'=>'osx_powerpc-8.5','us1-dir'=>'OSX/ppc'); $platforms[] = array('os'=>'dar', 'os_human'=>'OS X', 'arch'=>'x86', 'dirname'=>'osx_i386-8.11','us1-dir'=>'OSX/x86'); $platforms[] = array('os'=>'dar', 'os_human'=>'OS X', 'arch'=>'x86-64', 'dirname'=>'osx_x86-64-10.2','us1-dir'=>'OSX/x86_64'); $platforms[] = array('os'=>'sun', 'os_human'=>'Solaris', 'arch'=>'sparc', 'dirname'=>'solaris_sparc-5.9', 'us1-dir'=>'Solaris/sparc'); $platforms[] = array('os'=>'sun', 'os_human'=>'Solaris', 'arch'=>'x86', 'dirname'=>'solaris_i386-5.10','us1-dir'=>'Solaris/x86'); return $platforms; } function get_loader_platforms() { if (!isset($_SESSION['loader_platform_info'])) { $serialised_res = ''; $fp = @fopen(LOADER_PLATFORM_URL,'r'); if ($fp !== false) { $serialised_res = fgets($fp); } if (empty($serialised_res)) { $serialised_res = serialize(default_platform_list()); } $_SESSION['loader_platform_info'] = $serialised_res; } return unserialize($_SESSION['loader_platform_info']); } function get_platforminfo() { static $platforminfo; if (empty($platforminfo)) { $platforminfo = get_loader_platforms(); } return $platforminfo; } function supported_os_variants($os_code,$arch_code) { if (empty($os_code)) { return ERROR_UNKNOWN_OS; } if (empty($arch_code)) { return ERROR_UNKNOWN_ARCH; } $os_found = false; $arch_found = false; $os_arch_matches = array(); $pinfo = get_platforminfo(); foreach ($pinfo as $p) { if ($p['os'] == $os_code && $p['arch'] == $arch_code) { $os_arch_matches[$p['os_human']] = (isset($p['os_mod']))?str_replace('_','',$p['os_mod']):''; } if ($p['os'] == $os_code) { $os_found = true; } elseif ($p['arch'] == $arch_code) { $arch_found = true; } } if (!empty($os_arch_matches)) { asort($os_arch_matches); return $os_arch_matches; } elseif (!$os_found) { return ERROR_UNSUPPORTED_OS; } elseif (!$arch_found) { return ERROR_UNSUPPORTED_ARCH; } else { return ERROR_UNSUPPORTED_ARCH_OS; } } function supported_win_compilers() { static $win_compilers; if (empty($win_compilers)) { $win_compilers = find_win_compilers(); } return $win_compilers; } function find_win_compilers() { if (!isset($_SESSION['php_compilers_info'])) { $serialised_res = ''; $fp = @fopen(PHP_COMPILERS_URL,'r'); if ($fp !== false) { $serialised_res = fgets($fp); } if (empty($serialised_res)) { $serialised_res = serialize(array('VC6')); } $_SESSION['php_compilers_info'] = $serialised_res; } return unserialize($_SESSION['php_compilers_info']); } function server_software_info() { $ss = array('full' => '','short' => ''); $ss['full'] = $_SERVER['SERVER_SOFTWARE']; if (preg_match('/apache/i', $ss['full'])) { $ss['short'] = 'Apache'; } else if (preg_match('/IIS/',$ss['full'])) { $ss['short'] = 'IIS'; } else { $ss['short'] = ''; } return $ss; } function match_arch_pattern($str) { $arch = null; $arch_patterns = array( 'i.?86' => 'x86', 'x86[-_]64' => 'x86-64', 'x86' => 'x86', 'amd64' => 'x86-64', 'ppc64' => 'ppc64', 'ppc' => 'ppc', 'sparc' => 'sparc', 'sun' => 'sparc' ); foreach ($arch_patterns as $token => $a) { if (preg_match("/$token/i", $str)) { $arch = $a; break; } } return $arch; } function required_loader() { $un = php_uname(); $php_major_version = substr(PHP_VERSION,0,3); $os_name = substr($un,0,strpos($un,' ')); $os_code = empty($os_name)?'':strtolower(substr($os_name,0,3)); $wordsize = ((-1^0xffffffff) ? 64 : 32); if ($os_code == 'win') { $arch = ($wordsize == 32)?'x86':'x86-64'; if ($wordsize != 32) { return ERROR_WINDOWS_64_BIT; } } elseif (!empty($os_code)) { $arch = match_arch_pattern($un); } $os_variants = supported_os_variants($os_code,$arch); if (!is_array($os_variants)) { return $os_variants; } $os_ver = ''; if (preg_match('/([0-9.]+)/',php_uname('r'),$match)) { $os_ver = $match[1]; } $loader_sfix = (($os_code == 'win') ? 'dll' : 'so'); $file = "ioncube_loader_${os_code}_${php_major_version}.${loader_sfix}"; if ($os_code == 'win') { $os_name = 'Windows'; $file_ts = $file; } else { $os_names = array_keys($os_variants); $parts = explode(" ",$os_names[0]); $os_name = $parts[0]; $file_ts = "ioncube_loader_${os_code}_${php_major_version}_ts.${loader_sfix}"; } return array( 'arch' => $arch, 'oscode' => $os_code, 'osname' => $os_name, 'osvariants' => $os_variants, 'osver' => $os_ver, 'osver2' => preg_split('@\.@',$os_ver), 'file' => $file, 'file_ts' => $file_ts, 'wordsize' => $wordsize ); } function ic_system_info() { $thread_safe = null; $debug_build = null; $cgi_cli = false; $is_cgi = false; $is_cli = false; $php_ini_path = ''; $is_supported_compiler = true; $php_compiler = ''; ob_start(); phpinfo(INFO_GENERAL); $php_info = ob_get_contents(); ob_end_clean(); $breaker = (php_sapi_name() == 'cli')?'\n':''; $lines = explode($breaker,$php_info); foreach ($lines as $line) { if (preg_match('/command/i',$line)) { continue; } if (preg_match('/thread safety/i', $line)) { $thread_safe = (preg_match('/(enabled|yes)/i', $line) != 0); } if (preg_match('/debug build/i', $line)) { $debug_build = (preg_match('/(enabled|yes)/i', $line) != 0); } if (preg_match('~configuration file.*(Please note that the MS Windows installer version is suitable either for direct installation on a Windows machine or for
uploading from a local PC to your server.
";
echo 'A Loaders archive can also be downloaded from ' . LOADERS_PAGE . '.';
} else {
echo '
Please note that the MS Windows installer version is suitable for uploading from a Windows PC to your ${loader['osname']} server.
";
echo "
Note that you may need to install back compatibility libraries for ${loader['osname']}.
"; } } } echo 'On your shared server, the Loader must be installed using a $php_ini_name configuration file."; echo " (Please click here if you are not on a shared server.)
"; } if (own_php_ini_possible()) { $server_type = SERVER_SHARED_INI; echo 'With your hosting account, you may be able to use your own PHP configuration file.
'; } else { echo "It appears that you do not have access to the $php_ini_name file. Your server provider or system administrator should be able to perform the installation for you. Please refer them to the following instructions.
"; } php_ini_instruction_list($server_type); } function php_ini_install($server_type_desc = null, $server_type = SERVER_DEDICATED, $required = true) { $php_ini_name = ini_file_name(); $self = get_self(); echo ''; if ($server_type_desc) { echo "For a $server_type_desc server "; } else { echo "For this server "; } if ($required) { echo "you should install the ionCube Loader using the $php_ini_name configuration file."; } else { echo "installing the ionCube Loader using the $php_ini_name file is recommended."; } if ($server_type_desc) { echo " (Please click here if you are not on a $server_type_desc server.)"; } echo '
'; php_ini_instruction_list($server_type); } function php_ini_contents($loader_location) { $dbq = (is_ms_windows())?'"':''; $line = zend_extension_line_start() . ' = ' . $dbq . $loader_location . $dbq; return $line; } function help_resources($error_list = array()) { return (array( 'ionCube Loaders FAQ', 'ionCube Loader Forum', 'Raise a support ticket through our helpdesk')); } function support_ticket_information($error_list = array()) { $sys = get_sysinfo(); $ld = get_loaderinfo(); $ticket_strs = array(); $ticket_strs[] = "PLEASE DO NOT REMOVE THE FOLLOWING INFORMATION\r\n"; $ticket_strs[] = "==============\r\n"; if (!empty($error_list)) { $ticket_strs[] = "[hr]"; $ticket_strs[] = "ERRORS"; $ticket_strs[] = "[table]"; $ticket_strs[] = '[tr][td]' . join('[/td][/tr][tr][td]',$error_list) . '[/td][/tr]'; $ticket_strs[] = "[/table]"; } $ticket_strs[] = "[hr]"; $ticket_strs[] = "SYSTEM INFORMATION"; $ticket_strs[] = "[table]"; $info_lines = array(); $info_lines["Machine architecture"] = $ld['arch']; $info_lines["Operating system"] = $ld['osname'] . ' ' . $ld['osver']; $info_lines["PHP version"] = PHP_VERSION; if (!$sys['SUPPORTED_COMPILER']) { $info_lines["SUPPORTED PHP COMPILER"] = "FALSE"; $info_lines["PHP COMPILER"] = $sys['PHP_COMPILER']; } $info_lines["Is CLI?"] = ($sys['IS_CLI']?"Yes":"No"); $info_lines["Is CGI?"] = ($sys['IS_CGI']?"Yes":"No"); $info_lines["Is thread-safe?"] = ($sys['THREAD_SAFE']?"Yes":"No"); $info_lines["Web server"] = $sys['FULL_SS']; $info_lines[ "PHP ini file"] = $sys['PHP_INI']; if (!file_exists($sys['PHP_INI'])) { $info_lines["Ini file found"] = "INI FILE NOT FOUND"; } else { if (is_readable($sys['PHP_INI'])) { $info_lines["Ini file found"] = "INI FILE READABLE"; } else { $fh = fopen($sys['PHP_INI'],"rb"); if ($fh === false) { $info_lines["Ini file found"] = "INI FILE FOUND BUT POSSIBLY NOT READABLE"; } else { $info_lines["Ini file found"] = "INI FILE READABLE"; } } } $loader_path = find_loader(); if (is_string($loader_path)) { $info_lines["Loader path"] = $loader_path; $info_lines["Loader MD5 sum"] = md5_file($loader_path); } else { $info_lines["Loader path"] = "LOADER PATH NOT FOUND"; } $info_lines["Wizard script path"] = '[url]http://' . $_SERVER["HTTP_HOST"] . get_self() . '[/url]'; foreach ($info_lines as $h => $i) { $ticket_strs[] = '[tr][td]' . $h . '[/td]' . '[td]' . $i . '[/td][/tr]'; } $ticket_strs[] = '[/table]'; $ticket_strs[] = '[hr]'; $ticket_strs[] = "\r\n==============\r\n"; $ticket_strs[] = "PLEASE ENTER ANY ADDITIONAL INFORMATION BELOW\r\n"; $support_ticket_str = join('',$ticket_strs); return rawurlencode($support_ticket_str); } function os_arch_string_check($loader_str) { $errors = array(); if (preg_match("/target os:\s*([^_]+)_(.*)-/i",$loader_str,$os_matches)) { $loader_info = get_loaderinfo(); if (strtolower($loader_info['osname']) != $os_matches[1]) { $errors[] = "You have the wrong loader for your operating system, ". $loader_info['osname'] . "."; } elseif ($loader_info['arch'] != ($ap = match_arch_pattern($os_matches[2]))) { $err_str = "You have the wrong loaders for your machine architecture."; $err_str .= " Your system is " . $loader_info['arch']; $err_str .= " but the loader you are using is for " . $ap . "."; $errors[] = $err_str; } } return $errors; } function loader_compatibility_test($loader_location) { $errors = array(); $sysinfo = get_sysinfo(); if (LOADER_NAME_CHECK) { $installed_loader_name = basename($loader_location); $expected_loader_name = get_loader_name(); if ($installed_loader_name != $expected_loader_name) { $errors[] = "The installed loader ($installed_loader_name) does not have the name expected ($expected_loader_name) for your system. Please check that you have the correct Loader for your system."; } } if (empty($errors) && !is_readable($loader_location)) { $execute_error = "The loader at $loader_location does not appear to be readable."; $execute_error .= "The loader has been successfully installed by runtime loading using dl($rtl_path)
"; } else { echo "The loader has been successfully installed.
"; } } } function dedicated_server() { php_ini_install('dedicated or VPS', SERVER_DEDICATED, true); } function local_install() { php_ini_install('local',SERVER_LOCAL, true); } function unregister_globals() { if (!ini_get('register_globals')) { return; } if (isset($_REQUEST['GLOBALS']) || isset($_FILES['GLOBALS'])) { die('GLOBALS overwrite attempt detected'); } $noUnset = array('GLOBALS', '_GET', '_POST', '_COOKIE', '_REQUEST', '_SERVER', '_ENV', '_FILES'); $input = array_merge($_GET, $_POST, $_COOKIE, $_SERVER, $_ENV, $_FILES, isset($_SESSION) && is_array($_SESSION) ? $_SESSION : array()); foreach ($input as $k => $v) { if (!in_array($k, $noUnset) && isset($GLOBALS[$k])) { unset($GLOBALS[$k]); } } } function run() { unregister_globals(); if (is_php_version_or_greater(4,3,0)) { ini_set('session.use_only_cookies',1); } @session_start(); if (!isset($_SESSION['CREATED'])) { $_SESSION['CREATED'] = time(); } elseif (time() - $_SESSION['CREATED'] > SESSION_LIFETIME_MINUTES * 60) { $persist['not_go_daddy'] = empty($_SESSION['not_go_daddy'])?0:1; $persist['use_ini_method'] = empty($_SESSION['use_ini_method'])?0:1; $persist['on_shared_host'] = empty($_SESSION['on_shared_host'])?0:1; session_destroy(); $_SESSION = array(); $_SESSION = $persist; } if (!isset($_SERVER)) $_SERVER =& $HTTP_SERVER_VARS; (php_sapi_name() == 'cli') && die("This script should only be run by a web server.\n"); $page = get_request_parameter('page'); $host = get_request_parameter('host'); $clear = get_request_parameter('clear'); $ini = get_request_parameter('ini'); if (!empty($host)) { if ($host == 'ngd') { $_SESSION['not_go_daddy'] = 1; } } if (!empty($ini)) { $_SESSION['use_ini_method'] = 1; } if (!empty($clear)) { unset($_SESSION['latest_version']); unset($_SESSION['loader_platform_info']); unset($_SESSION['loader_version_info']); unset($_SESSION['php_compilers_info']); unset($_SESSION['not_go_daddy']); unset($_SESSION['use_ini_method']); unset($_SESSION['on_shared_host']); } if (empty($_SESSION['latest_version'])) { $_SESSION['latest_version'] = retrieve_latest_version(); } if (!empty($page)) { $fn = "${page}_page"; if (function_exists($fn)) { $fn(); } else { default_page(); } } else { $godaddy_root = GoDaddy_root(); if (empty($godaddy_root)) { default_page(); } else { GoDaddy_page($godaddy_root); } } @session_write_close(); exit(0); } function default_page($loader_extension = LOADER_EXTENSION_NAME) { $self = get_self(); foreach (array('self') as $vn) { if (empty($$vn)) { error("Unable to initialise ($vn)."); } } heading(); $wizard_update = check_for_wizard_update(true); if (extension_loaded($loader_extension)) { loader_already_installed(); } else { loader_not_installed(); } footer($wizard_update); } function uninstall_wizard_instructions() { echo 'For security reasons we advise that you remove this Wizard script from your server now that the Loader is installed.
'; } function contact_script_provider_instructions() { echo 'Please contact the script provider if you do experience any problems running encoded files.
'; } function loader_already_installed() { list($lv,$old_version) = ioncube_loader_version_information(); echo ""; if ($old_version) { echo 'The ionCube Loader ' . $lv . ' is already installed but it is an old version. It is recommended that the Loader be updated to the latest version from the ionCube Loaders page if one is available for your platform.
'; } else { echo 'The ionCube Loader ' . $lv . ' is already installed and encoded files should run without problems.'; } echo "
"; contact_script_provider_instructions(); uninstall_wizard_instructions(); } function loader_not_installed() { $loader = get_loaderinfo(); $sysinfo = get_sysinfo(); $stype = get_request_parameter('stype'); $manual_select = get_request_parameter('manual'); if (isset($stype)) { $_SESSION['on_shared_host'] = $stype == 's'; } elseif (!isset($_SESSION['on_shared_host'])) { $_SESSION['on_shared_host'] = is_shared(); } if (!$manual_select && empty($_SESSION['use_ini_method']) && $_SESSION['on_shared_host'] && runtime_loading_is_possible()) { $errors = runtime_loading_errors(); } else { $errors = ini_loader_errors(); } if (!empty($errors)) { if (count($errors) > 1) { $problem_str = "Please note that the following problems currently exist"; } else { $problem_str = "Please note that the following problem currently exists"; } echo 'To use files that have been protected by the ionCube PHP Encoder, a component called the ionCube Loader must be installed.
'; } if (!is_array($loader)) { if ($loader == ERROR_WINDOWS_64_BIT) { echo 'Loaders for 64-bit PHP on Windows are not currently available. However, if you install and run 32-bit PHP the corresponding 32-bit Loader for Windows should work.
'; if ($sysinfo['THREAD_SAFE']) { echo 'There may not be a Loader available for your type of system at the moment, however if you create a support ticket more advice and information may be available to assist. Please include the URL for this Wizard in your ticket.
'; } } else { if (!is_supported_php_version()) { echo 'Your server is running PHP version ' . PHP_VERSION . ' and is unsupported by ionCube Loaders. Recommended PHP 4 versions are PHP 4.2 or higher, and PHP 5.1 or higher for PHP 5.
'; } elseif (!$sysinfo['SUPPORTED_COMPILER']) { $supported_compilers = supported_win_compilers(); $supported_compiler_string = join('/',$supported_compilers); echo 'At the current time the ionCube Loader requires PHP to be built with ' . $supported_compiler_string . '. Your PHP software has been built using ' . $sysinfo['PHP_COMPILER'] . '. Supported builds of PHP are available from PHP.net.';
} else {
if (!in_array($stype,array('s','d','l'))) {
if (!$manual_select && is_local()) {
local_install();
} elseif (!$manual_select && !is_possibly_dedicated_or_local()) {
shared_server();
} else {
echo server_selection_form();
}
} else {
switch ($stype) {
case 's':
shared_server();
break;
case 'd':
dedicated_server();
break;
case 'l':
local_install();
break;
}
}
}
}
}
function server_selection_form()
{
$self = get_self();
$form = <<
Please select the type of web server that you have and then click Next.
EOT; return $form; } function phpinfo_page() { phpinfo(); } function loader_check_page($ext_name = LOADER_EXTENSION_NAME) { heading(); $rtl_path = null; if (empty($_SESSION['use_ini_method']) && !empty($_SESSION['on_shared_host']) && runtime_loading_is_possible()) { $rtl_path = runtime_loading(); } if (extension_loaded($ext_name)) { list($lv,$is_old) = ioncube_loader_version_information(); echo 'The ionCube Loader ' . $lv . ' is installed and encoded files should run successfully.
'; contact_script_provider_instructions(); uninstall_wizard_instructions(); } else { echo 'The ionCube Loader is not currently installed successfully.
'; if (!is_null($rtl_path)) { echo 'Runtime loading was attempted but has failed.
'; $rt_errors = runtime_loading_errors(); if (!empty($rt_errors)) { list_loader_errors($rt_errors); } else { $self = get_self(); echo "Please click here for instructions on using the php.ini method instead.
"; } } else { list_loader_errors(); } } footer(true); } function ini_loader_errors() { $errors = array(); $loader_loc = find_loader(); if (is_string($loader_loc)) { $errors = loader_compatibility_test($loader_loc); } else { $errors = $loader_loc; } return $errors; } function list_loader_errors($errors = array(),$suggest_restart = true) { $self = get_self(); $retry_message = ''; if (empty($errors)) { $errors = ini_loader_errors(); } if (!empty($errors)) { $try_again = 'try again'; echo 'Please check that the $ss web server software has been restarted.
"; } echo '";
if (is_string($loader_path)) {
echo "Loader is at " . $loader_path;
echo "
MD5 sum is " . md5_file($loader_path);
if (0 === strpos($loader_path,$_SERVER['DOCUMENT_ROOT'])) {
$s = strlen($_SERVER['DOCUMENT_ROOT']);
$loader_url = 'http://' . $_SERVER["HTTP_HOST"] . preg_replace('@\\\\@','/',substr($loader_path,$s));
echo "
Download Loader from $loader_url";
} else {
echo "
Loader is not within the document root at " . $_SERVER['DOCUMENT_ROOT'];
}
} else {
echo "Loader cannot be found";
}
echo "
It appears that you are hosted with GoDaddy (www.godaddy.com). '; $inst_str .= "If that is not the case then please click here to go to the main page of this installation wizard.
"; $inst_str .= "If you have already installed the loader then please click here to test the Loader.
"; echo $inst_str; if (is_ms_windows()) { GoDaddy_windows_instructions(); } else { GoDaddy_linux_instructions($home_dir); } footer(true); } function get_request_parameter($param_name) { static $request_array; if (!isset($request_array)) { if (isset($_GET)) { $request_array = $_GET; } elseif (isset($HTTP_GET_VARS)) { $request_array = $HTTP_GET_VARS; } } if (isset($request_array[$param_name])) { return $request_array[$param_name]; } else { return null; } } function make_list($list_items,$list_type='ol') { $html = ''; if (!empty($list_items)) { $html .= "<$list_type>"; $html .= 'Please help us improve this script by reporting this error and including the URL to the script so that we can test it.");
}
function get_self()
{
return @$_SERVER['PHP_SELF'];
}
function heading()
{
$self = get_self();
echo <<ionCube Loader Wizard
EOT;
}
function footer($update_info = null)
{
$self = get_self();
$year = date("Y");
echo "
#%MENU_START%##%CAT_TITLE%# #%CAT_SITES%# #%MENU_END%#
#
Category
Description
Click
Out