'.$name .' | -'.$size.' | -× | - '; - $count++; - } - } - - ?> -
-
From 93ded44f58cfcf07e0f98e043c05406d4afc8dd9 Mon Sep 17 00:00:00 2001
From: kjodle '. $counter .' '.i18n_r('TOTAL_FILES').' ('. fSize($totalsize) .') <img src="" class="gs_image" height="" width="" alt=""> <img src="" class="gs_image gs_thumb" height="" width="" alt=""> <a href="" class="gs_image_link" ><img src="" class="gs_thumb" height="" width="" alt="" /></a>
-
-
-
- '.$name .'
- '.$size.'
- ×
- ';
- $count++;
- }
- }
-
- ?>
- ‘’
-
-
-
-
-
-
-
- :
- :
- '. find_url($url, $parent) .'';
- }
- ?>
-
- :
- :
- :
- :
- :
- ';
-
- if ($page['title'] == '' ) { $page['title'] = '[No Title] » '. $page['url'] .''; }
-
- $table .= ' ';
- }
-}
-
-get_template('header', cl($SITENAME).' » '.i18n_r('BAK_MANAGEMENT'));
-
-?>
-
-
-
-'. cl($page['title']) .' ';
- $table .= ''. shtDate($page['date']) .' ';
- $table .= '× ';
- $table .= '
-------
";
- echo 'Invalid Referer: ' . htmlentities($_SERVER['HTTP_REFERER'], ENT_QUOTES);
- die('Invalid Referer');
- }
-}
-
-login_cookie_check();
-
-if (isset($_POST['submitted'])) {
-
- // check for csrf
- if (!defined('GSNOCSRF') || (GSNOCSRF == FALSE) ) {
- $nonce = $_POST['nonce'];
- if(!check_nonce($nonce, "edit", "edit.php")) {
- die("CSRF detected!");
- }
- }
-
- if ( trim($_POST['post-title']) == '' ) {
- redirect("edit.php?upd=edit-error&type=".urlencode(i18n_r('CANNOT_SAVE_EMPTY')));
- } else {
-
- $url="";$title="";$metad=""; $metak=""; $cont="";
-
- // is a slug provided?
- if ($_POST['post-id']) {
- $url = trim($_POST['post-id']);
- if (isset($i18n['TRANSLITERATION']) && is_array($translit=$i18n['TRANSLITERATION']) && count($translit>0)) {
- $url = str_replace(array_keys($translit),array_values($translit),$url);
- }
- $url = to7bit($url, "UTF-8");
- $url = clean_url($url); //old way
- } else {
- if ($_POST['post-title']) {
- $url = trim($_POST['post-title']);
- if (isset($i18n['TRANSLITERATION']) && is_array($translit=$i18n['TRANSLITERATION']) && count($translit>0)) {
- $url = str_replace(array_keys($translit),array_values($translit),$url);
- }
- $url = to7bit($url, "UTF-8");
- $url = clean_url($url); //old way
- } else {
- $url = "temp";
- }
- }
-
-
- //check again to see if the URL is empty
- if ( trim($url) == '' ) {
- $url = 'temp';
- }
-
-
- // was the slug changed on an existing page?
- if ( isset($_POST['existing-url']) ) {
- if ($_POST['post-id'] != $_POST['existing-url']){
- // dont change the index page's slug
- if ($_POST['existing-url'] == 'index') {
- $url = $_POST['existing-url'];
- redirect("edit.php?id=". urlencode($_POST['existing-url']) ."&upd=edit-index&type=edit");
- } else {
- exec_action('changedata-updateslug');
- updateSlugs($_POST['existing-url']);
- $file = GSDATAPAGESPATH . $url .".xml";
- $existing = GSDATAPAGESPATH . $_POST['existing-url'] .".xml";
- $bakfile = GSBACKUPSPATH."pages/". $_POST['existing-url'] .".bak.xml";
- copy($existing, $bakfile);
- unlink($existing);
- }
- }
- }
-
- $file = GSDATAPAGESPATH . $url .".xml";
-
- // format and clean the responses
- if(isset($_POST['post-title'])) { $title = safe_slash_html($_POST['post-title']); }
- if(isset($_POST['post-metak'])) { $metak = safe_slash_html($_POST['post-metak']); }
- if(isset($_POST['post-metad'])) { $metad = safe_slash_html($_POST['post-metad']); }
- if(isset($_POST['post-author'])) { $author = safe_slash_html($_POST['post-author']); }
- if(isset($_POST['post-template'])) { $template = $_POST['post-template']; }
- if(isset($_POST['post-parent'])) { $parent = $_POST['post-parent']; }
- if(isset($_POST['post-menu'])) { $menu = safe_slash_html($_POST['post-menu']); }
- if(isset($_POST['post-menu-enable'])) { $menuStatus = "Y"; } else { $menuStatus = ""; }
- if(isset($_POST['post-private']) ) { $private = safe_slash_html($_POST['post-private']); }
- if(isset($_POST['post-content'])) { $content = safe_slash_html($_POST['post-content']); }
- if(isset($_POST['post-menu-order'])) {
- if (is_numeric($_POST['post-menu-order']))
- {
- $menuOrder = $_POST['post-menu-order'];
- }
- else
- {
- $menuOrder = "0";
- }
- }
- // If saving a new file do not overwrite existing, get next incremental filename, file-count.xml
- if ( (file_exists($file) && $url != $_POST['existing-url']) || in_array($url,$reservedSlugs) ) {
- $count = "1";
- $file = GSDATAPAGESPATH . $url ."-".$count.".xml";
- while ( file_exists($file) ) {
- $count++;
- $file = GSDATAPAGESPATH . $url ."-".$count.".xml";
- }
- $url = $url .'-'. $count;
- }
-
-
- // if we are editing an existing page, create a backup
- if ( file_exists($file) )
- {
- $bakfile = GSBACKUPSPATH."pages/". $url .".bak.xml";
- copy($file, $bakfile);
- }
-
-
- $xml = new SimpleXMLExtended('
';
- $table .= '';
- $table .= '';
- $table .= '';
- $table .= '';
- exec_action('component-extras');
- $table .= ''. stripslashes($component->title) .' ';
- $table .= '<?php get_component(\''.$component->slug.'\'); ?>
';
- $table .= '× /
-/ uploads / ';
- foreach ($pathParts as $pathPart){
- if ($pathPart!=''){
- $urlPath.=$pathPart."/";
- echo ''.$pathPart.' / ';
- }
- }
- echo "';
-
- if (count($dirsSorted) != 0) {
- foreach ($dirsSorted as $upload) {
- echo '
';
- echo '';
- echo ' ';
- }
- }
-
- if (count($filesSorted) != 0) {
- foreach ($filesSorted as $upload) {
- $upload['name'] = rawurlencode($upload['name']);
- $thumb = null; $thumbnailLink = null;
- $subDir = ($subPath == '' ? '' : $subPath.'/');
- $selectLink = 'title="'.i18n_r('SELECT_FILE').': '. htmlspecialchars($upload['name']) .'" href="javascript:void(0)" onclick="submitLink('.$CKEditorFuncNum.',\''.$fullPath.$subDir.$upload['name'].'\')"';
-
- if ($type == 'images') {
- if ($upload['type'] == i18n_r('IMAGES') .' Images') {
- # get internal thumbnail to show beside link in table
- $thumb = '';
- $adm = substr($path . $upload['name'] , 16);
- if ($returnid!='') {
- $returnlink = '&returnid='.$returnid;
- } else {
- $returnlink='';
- }
- if ($func!='') {
- $funct = '&func='.$func;
- } else {
- $funct='';
- }
- echo ' ';
- echo ' '.$upload['name'].'';
- echo '
';
- $thumbLink = $urlPath.'thumbsm.'.$upload['name'];
- if (file_exists('../data/thumbs/'.$thumbLink)) {
- $imgSrc=' ';
-
- # get external thumbnail link
- $thumbLinkExternal = 'data/thumbs/'.$urlPath.'thumbnail.'.$upload['name'];
- if (file_exists('../'.$thumbLinkExternal)) {
- $thumbnailLink = ' – '.i18n_r('THUMBNAIL').'';
- }
- }
- else { continue; }
- }
-
- $counter++;
-
- echo '';
- } else {
- $imgSrc='
';
- }
- $thumb .= ''.$imgSrc.'';
- $thumb .= '
';
- echo ($thumb=='' ? ' ';
- }
-
- }
- echo ' ' : $thumb);
- echo ''.htmlspecialchars($upload['name']) .''.$thumbnailLink.' ';
- echo ''. $upload['size'] .' ';
-
- // get the file permissions.
- if ($isUnixHost && isDebug() && function_exists('posix_getpwuid')) {
- $filePerms = substr(sprintf('%o', fileperms($path.$upload['name'])), -4);
- $fileOwner = posix_getpwuid(fileowner($path.$upload['name']));
- echo ''.$fileOwner['name'].'/'.$filePerms.' ';
- }
-
- echo ''. shtDate($upload['date']) .' ';
- echo '
- status;
- } else {
- $verstatus = null;
- }
- if ($verstatus == '0') {
- $ver = ''.$site_version_no.'
-
-
-
'. i18n_r('UPG_NEEDED').' ('.$apikey->latest .')
'. i18n_r('DOWNLOAD').'';
- } elseif ($verstatus == '1') {
- $ver = ''.$site_version_no.'
'. i18n_r('LATEST_VERSION').'';
- } elseif ($verstatus == '2') {
- $ver = ''.$site_version_no.'
'. i18n_r('BETA').'';
- } else {
- $ver = ''.$site_version_no.'
'. i18n_r('CANNOT_CHECK').'
'. i18n_r('DOWNLOAD').'';
- }
- ?>
-
- GSADMIN '.GSADMIN.' ';
-
- if(defined('GSLOGINSALT') && GSLOGINSALT!='') echo ' ';
- else echo 'GSLOGINSALT '. i18n_r('YES').' ';
-
- if(defined('GSUSECUSTOMSALT') && GSUSECUSTOMSALT!='') echo 'GSLOGINSALT '. i18n_r('NO').' ';
- else echo 'GSUSECUSTOMSALT '. i18n_r('YES').' ';
- ?>
- GSUSECUSTOMSALT '. i18n_r('NO').'
-
-
-
-
- ';
- } else {
- echo 'PHP '.i18n_r('VERSION').'
- '. PHP_VERSION.' - PHP 5.2 '.i18n_r('OR_GREATER_REQ').' - '.i18n_r('ERROR').' '. PHP_VERSION.' - '.i18n_r('OK').' ';
- }
-
- if (in_arrayi('curl', $php_modules) && function_exists('curl_init') && function_exists('curl_exec')) {
- echo ' ';
- } else{
- echo 'cURL Module '.i18n_r('INSTALLED').' - '.i18n_r('OK').' ';
- }
- if (in_arrayi('gd', $php_modules) ) {
- echo 'cURL Module '.i18n_r('NOT_INSTALLED').' - '.i18n_r('WARNING').' ';
- } else{
- echo 'GD Library '.i18n_r('INSTALLED').' - '.i18n_r('OK').' ';
- }
- if (in_arrayi('zip', $php_modules) ) {
- echo 'GD Library '.i18n_r('NOT_INSTALLED').' - '.i18n_r('WARNING').' ';
- } else{
- echo 'ZipArchive '.i18n_r('INSTALLED').' - '.i18n_r('OK').' ';
- }
- if (! in_arrayi('SimpleXML', $php_modules) ) {
- echo 'ZipArchive '.i18n_r('NOT_INSTALLED').' - '.i18n_r('WARNING').' ';
- } else {
- echo 'SimpleXML Module '.i18n_r('NOT_INSTALLED').' - '.i18n_r('ERROR').' ';
- }
- if (!function_exists('chmod') ) {
- echo 'SimpleXML Module '.i18n_r('INSTALLED').' - '.i18n_r('OK').' ';
- } else {
- echo 'chmod '.i18n_r('NOT_INSTALLED').' - '.i18n_r('ERROR').' ';
- }
-
- if (server_is_apache()) {
- echo 'chmod chmod - '.i18n_r('OK').' ';
- if ( function_exists('apache_get_modules') ) {
- if(! in_arrayi('mod_rewrite',apache_get_modules())) {
- echo 'Apache Web Server '.$_SERVER['SERVER_SOFTWARE'].' - '.i18n_r('OK').' ';
- } else {
- echo 'Apache Mod Rewrite '.i18n_r('NOT_INSTALLED').' - '.i18n_r('WARNING').' ';
- }
- } else {
- echo 'Apache Mod Rewrite '.i18n_r('INSTALLED').' - '.i18n_r('OK').' ';
- }
- } else {
- if (!defined('GSNOAPACHECHECK') || GSNOAPACHECHECK == false) {
- echo 'Apache Mod Rewrite '.i18n_r('INSTALLED').' - '.i18n_r('OK').' ';
- }
- }
-
- $disabled_funcs = ini_get('disable_functions');
- if(!empty($disabled_funcs)) echo 'Apache web server '.$_SERVER['SERVER_SOFTWARE'].' - '.i18n_r('ERROR').' ';
- ?>
- PHP disable_functions ' . $disabled_funcs . '
-
-
-
- /data/pages/' . $file .' ' . valid_xml($path . $file) .' ';
- }
- }
-
- $path = GSDATAOTHERPATH;
- $data = getFiles($path);
- sort($data);
- foreach($data as $file) {
- if( isFile($file, $path) ) {
- echo ' ';
- }
- }
-
- $path = GSDATAOTHERPATH.'logs/';
- $data = getFiles($path);
- sort($data);
- foreach($data as $file) {
- if( isFile($file, $path, '.log') ) {
- echo '/data/other/' . $file .' ' . valid_xml($path . $file) .' ';
- }
- }
-
- $path = GSUSERSPATH;
- $data = getFiles($path);
- sort($data);
- foreach($data as $file) {
- if( isFile($file, $path) ) {
- echo '/data/other/logs/' . $file .' ' . valid_xml($path . $file) .' ';
- }
- }
- ?>
- /backups/users/' . $file .' ' . valid_xml($path . $file) .'
-
-
-
-
-
- : /data/other/plugins.xml = '0644' ) { echo ''. $me .' '.i18n_r('WRITABLE').' - '.i18n_r('OK').''; } else { echo ''. $me .' '.i18n_r('NOT_WRITABLE').' - '.i18n_r('ERROR').'!'; } ?>
- /data/pages/ = '0755' ) { echo ''. $me .' '.i18n_r('WRITABLE').' - '.i18n_r('OK').''; } else { echo ''. $me .' '.i18n_r('NOT_WRITABLE').' - '.i18n_r('ERROR').'!'; } ?>
- /data/other/ = '0755' ) { echo ''. $me .' '.i18n_r('WRITABLE').' - '.i18n_r('OK').''; } else { echo ''. $me .' '.i18n_r('NOT_WRITABLE').' - '.i18n_r('ERROR').'!'; } ?>
- /data/other/logs/ = '0755' ) { echo ''. $me .' '.i18n_r('WRITABLE').' - '.i18n_r('OK').''; } else { echo ''. $me .' '.i18n_r('NOT_WRITABLE').' - '.i18n_r('ERROR').'!'; } ?>
- /data/thumbs/ = '0755' ) { echo ''. $me .' '.i18n_r('WRITABLE').' - '.i18n_r('OK').''; } else { echo ''. $me .' '.i18n_r('NOT_WRITABLE').' - '.i18n_r('ERROR').'!'; } ?>
- /data/uploads/ = '0755' ) { echo ''. $me .' '.i18n_r('WRITABLE').' - '.i18n_r('OK').''; } else { echo ''. $me .' '.i18n_r('NOT_WRITABLE').' - '.i18n_r('ERROR').'!'; } ?>
- /data/users/ = '0755' ) { echo ''. $me .' '.i18n_r('WRITABLE').' - '.i18n_r('OK').''; } else { echo ''. $me .' '.i18n_r('NOT_WRITABLE').' - '.i18n_r('ERROR').'!'; } ?>
- /data/cache/ = '0755' ) { echo ''. $me .' '.i18n_r('WRITABLE').' - '.i18n_r('OK').''; } else { echo ''. $me .' '.i18n_r('NOT_WRITABLE').' - '.i18n_r('ERROR').'!'; } ?>
- /backups/zip/ = '0755' ) { echo ''. $me .' '.i18n_r('WRITABLE').' - '.i18n_r('OK').''; } else { echo ''. $me .' '.i18n_r('NOT_WRITABLE').' - '.i18n_r('ERROR').'!'; } ?>
- /backups/pages/ = '0755' ) { echo ''. $me .' '.i18n_r('WRITABLE').' - '.i18n_r('OK').''; } else { echo ''. $me .' '.i18n_r('NOT_WRITABLE').' - '.i18n_r('ERROR').'!'; } ?>
- /backups/other/ = '0755' ) { echo ''. $me .' '.i18n_r('WRITABLE').' - '.i18n_r('OK').''; } else { echo ''. $me .' '.i18n_r('NOT_WRITABLE').' - '.i18n_r('ERROR').'!'; } ?>
- /backups/users/ = '0755' ) { echo ''. $me .' '.i18n_r('WRITABLE').' - '.i18n_r('OK').''; } else { echo ''. $me .' '.i18n_r('NOT_WRITABLE').' - '.i18n_r('ERROR').'!'; } ?>
-
-
-
-
- /data/
- '.i18n_r('MISSING_FILE').' - '.i18n_r('WARNING').'';
- } else {
- $res = file_get_contents($file);
- if ( !strstr($res, 'Deny from all')) {
- echo ''.i18n_r('BAD_FILE').' - '.i18n_r('WARNING').'';
- } else {
- echo ''.i18n_r('GOOD_D_FILE').' - '.i18n_r('OK').'';
- }
- }
- ?>
-
-
- /data/uploads/
- '.i18n_r('MISSING_FILE').' - '.i18n_r('WARNING').'';
- } else {
- $res = file_get_contents($file);
- if ( !strstr($res, 'Allow from all')) {
- echo ' '.i18n_r('BAD_FILE').' - '.i18n_r('WARNING').'';
- } else {
- echo ' '.i18n_r('GOOD_A_FILE').' - '.i18n_r('OK').'';
- }
- }
- ?>
-
-
- /data/users/
- '.i18n_r('MISSING_FILE').' - '.i18n_r('WARNING').'';
- } else {
- $res = file_get_contents($file);
- if ( !strstr($res, 'Deny from all')) {
- echo ''.i18n_r('BAD_FILE').' - '.i18n_r('WARNING').'';
- } else {
- echo ''.i18n_r('GOOD_D_FILE').' - '.i18n_r('OK').'';
- }
- }
- ?>
-
-
- /data/cache/
- '.i18n_r('MISSING_FILE').' - '.i18n_r('WARNING').'';
- } else {
- $res = file_get_contents($file);
- if ( !strstr($res, 'Deny from all')) {
- echo ''.i18n_r('BAD_FILE').' - '.i18n_r('WARNING').'';
- } else {
- echo ''.i18n_r('GOOD_D_FILE').' - '.i18n_r('OK').'';
- }
- }
- ?>
-
-
- /data/thumbs/
- '.i18n_r('MISSING_FILE').' - '.i18n_r('WARNING').'';
- } else {
- $res = file_get_contents($file);
- if ( !strstr($res, 'Allow from all')) {
- echo ' '.i18n_r('BAD_FILE').' - '.i18n_r('WARNING').'';
- } else {
- echo ' '.i18n_r('GOOD_A_FILE').' - '.i18n_r('OK').'';
- }
- }
- ?>
-
-
- /data/pages/
- '.i18n_r('MISSING_FILE').' - '.i18n_r('WARNING').'';
- } else {
- $res = file_get_contents($file);
- if ( !strstr($res, 'Deny from all')) {
- echo ' '.i18n_r('BAD_FILE').' - '.i18n_r('WARNING').'';
- } else {
- echo ' '.i18n_r('GOOD_D_FILE').' - '.i18n_r('OK').'';
- }
- }
- ?>
-
-
- /plugins/
- '.i18n_r('MISSING_FILE').' - '.i18n_r('WARNING').'';
- } else {
- $res = file_get_contents($file);
- if ( !strstr($res, 'Deny from all')) {
- echo ' '.i18n_r('BAD_FILE').' - '.i18n_r('WARNING').'';
- } else {
- echo ' '.i18n_r('GOOD_D_FILE').' - '.i18n_r('OK').'';
- }
- }
- ?>
-
-
- /data/other/
- '.i18n_r('MISSING_FILE').' - '.i18n_r('WARNING').'';
- } else {
- $res = file_get_contents($file);
- if ( !strstr($res, 'Deny from all')) {
- echo ' '.i18n_r('BAD_FILE').' - '.i18n_r('WARNING').'';
- } else {
- echo ' '.i18n_r('GOOD_D_FILE').' - '.i18n_r('OK').'';
- }
- }
- ?>
-
-
- /data/other/logs/
- '.i18n_r('MISSING_FILE').' - '.i18n_r('WARNING').'';
- } else {
- $res = file_get_contents($file);
- if ( !strstr($res, 'Deny from all')) {
- echo ' '.i18n_r('BAD_FILE').' - '.i18n_r('WARNING').'';
- } else {
- echo ' '.i18n_r('GOOD_D_FILE').' - '.i18n_r('OK').'';
- }
- }
- ?>
-
- /theme/
- '.i18n_r('CANNOT_DEL_FILE').' - '.i18n_r('ERROR').'';
- } else {
- echo ' '.i18n_r('NO_FILE').' - '.i18n_r('OK').'';
- }
- ?>
- '.$thwidth.'x'.$thheight.'
';
-}else{
- // if thumb is missing recreate it
- require_once('inc/imagemanipulation.php');
- if(genStdThumb($subPath,$src)){
- list($thwidth, $thheight, $thtype, $athttr) = getimagesize($thumb_folder . 'thumbnail.'.$src);
- $thumb_exists = ' | '.i18n_r('CURRENT_THUMBNAIL').' '.$thwidth.'x'.$thheight.'
';
- }
-}
-
-get_template('header', cl($SITENAME).' » '.i18n_r('FILE_MANAGEMENT').' » '.i18n_r('IMAGES'));
-
-include('template/include-nav.php'); ?>
-
-'.$imgwidth.'x'.$imgheight .'
'. $thumb_exists .''; ?>
-
-
-
-
x
- * The mode to use to open the archive. - *
- * ZIPARCHIVE::OVERWRITE - *
- * @return mixed Error codes - *- * Returns true on success or the error code. - *
- * ZIPARCHIVE::ER_EXISTS - *
- *- * ZIPARCHIVE::ER_INCONS - *
- *- * ZIPARCHIVE::ER_INVAL - *
- *- * ZIPARCHIVE::ER_MEMORY - *
- *- * ZIPARCHIVE::ER_NOENT - *
- *- * ZIPARCHIVE::ER_NOZIP - *
- *- * ZIPARCHIVE::ER_OPEN - *
- *- * ZIPARCHIVE::ER_READ - *
- *- * ZIPARCHIVE::ER_SEEK - *
- * - */ - public function open ($filename, $flags = null) { - - if( is_dir($filename) ){ - return self::ER_NOZIP; - } - - //if zip file exists already exists - if( is_file($filename) ){ - - if( !is_readable($filename) ){ - return self::ER_READ; - } - - //if user asked for error then return it - if( $flags & self::EXCL ){ - return self::ER_EXISTS; - } - //if need to create new file but overwrite flag is not defined - if(($flags & self::CREATE) && !($flags & self::OVERWRITE) ){ - return self::ER_EXISTS; - } - } - - //if overwrite then remove file - if($flags & self::OVERWRITE){ - if( is_file($filename) ){ - if ( !(@unlink($filename)) ){ - return self::ER_READ; - } - } - } - - - //create/extract directory layout in temporary folder - - - //create temp dir - $tempDir = sys_get_temp_dir(); - if( $tempDir[strlen($tempDir)-1] != DIRECTORY_SEPARATOR ){ - $tempDir = $tempDir . DIRECTORY_SEPARATOR; - } - $this->tempDirPath = $tempDir.__CLASS__. uniqid(); - if( @mkdir($this->tempDirPath) !== true ) { - return self::ER_OPEN; - } - - if( is_file($filename) ){ - //extract zip file to tempDir - if( !$this->__extractTo($filename,$this->tempDirPath) ){ - return self::ER_OPEN; - } - } - - if($filename[0] == '/'){ - $this->zipFilePath = $filename; - }else{ - $this->zipFilePath = getcwd() .DIRECTORY_SEPARATOR. $filename; - } - $this->zip_is_open = true; - - return true; - } - - /** - * Close the active archive (opened or newly created) - * @link http://php.net/manual/en/function.ziparchive-close.php - * @return bool Returns true on success or false on failure. - */ - public function close () { - if(!$this->zip_is_open){ - return false; - } - - - if( strtolower(substr($this->zipFilePath, strlen($this->zipFilePath)-4)) == ".zip" ){ - //if $this->zipFilePath has .zip in the end then use this path for zip - $target_zip_file = $this->zipFilePath; - }else{ - //else use {$this->tempDirPath}.zip as zip file and then move it to final location - $target_zip_file = $this->tempDirPath . ".zip"; - } - - - $currentWorkingDir = getcwd(); - if( @chdir($this->tempDirPath) !== True){ - //unable to chdir to temp directory - return false; - } - - exec(self::$zip_exec." -m -r {$target_zip_file} * 2>&1", $output, $return_value); - chdir($currentWorkingDir); - - if($target_zip_file != $this->zipFilePath){ - if( @rename($target_zip_file, $this->zipFilePath) !== true){ - //if unable to copy zip to final destination then return false - return false; - } - } - - if($return_value != 0){ - return false; - } - - //remove trailing tempdir - @rmdir($this->tempDirPath); - - //do cleanup - $this->zip_is_open = false; - $this->zipFilePath = ""; - $this->tempDirPath = ""; - $this->fileIndex = array(); - - return true; - } - - /** - * Add a new directory - * @link http://php.net/manual/en/function.ziparchive-addemptydir.php - * @param dirname string- * The directory to add. - *
- * @return bool Returns true on success or false on failure. - */ - public function addEmptyDir ($dirname) { - if(!$this->zip_is_open){ - return false; - } - return mkdir($this->tempDirPath .DIRECTORY_SEPARATOR. $dirname ); - } - - /** - * Add a file to a ZIP archive using its contents - * @link http://php.net/manual/en/function.ziparchive-addfromstring.php - * @param localname string- * The name of the entry to create. - *
- * @param contents string- * The contents to use to create the entry. It is used in a binary - * safe mode. - *
- * @return bool Returns true on success or false on failure. - */ - public function addFromString ($localname, $contents) { - if(!$this->zip_is_open){ - return false; - } - $target_dir = $this->tempDirPath .DIRECTORY_SEPARATOR. dirname($localname); - $taget_file = basename($localname); - - //create directory if it does not exist - if( ! is_dir($target_dir) ){ - if(! mkdir($target_dir,0777,true) ){ - return false; - } - } - //create file from string - if( file_put_contents($target_dir.DIRECTORY_SEPARATOR.$taget_file,$contents) === False){ - return false; - } - return true; - } - - /** - * Adds a file to a ZIP archive from the given path - * @link http://php.net/manual/en/function.ziparchive-addfile.php - * @param filename string- * The path to the file to add. - *
- * @param localname string[optional]- * local name inside ZIP archive. - *
- * @return bool Returns true on success or false on failure. - */ - public function addFile ($filename, $localname = null) {} - - /** - * Renames an entry defined by its index - * @link http://php.net/manual/en/function.ziparchive-renameindex.php - * @param index int- * Index of the entry to rename. - *
- * @param newname string- * New name. - *
- * @return bool Returns true on success or false on failure. - */ - public function renameIndex ($index, $newname) {} - - /** - * Renames an entry defined by its name - * @link http://php.net/manual/en/function.ziparchive-renamename.php - * @param name string- * Name of the entry to rename. - *
- * @param newname string- * New name. - *
- * @return bool Returns true on success or false on failure. - */ - public function renameName ($name, $newname) {} - - /** - * Set the comment of a ZIP archive - * @link http://php.net/manual/en/function.ziparchive-setarchivecomment.php - * @param comment string- * The contents of the comment. - *
- * @return mixed Returns true on success or false on failure. - */ - public function setArchiveComment ($comment) {} - - /** - * Returns the Zip archive comment - * @link http://php.net/manual/en/function.ziparchive-getarchivecomment.php - * @return string the Zip archive comment or false on failure. - */ - public function getArchiveComment () {} - - /** - * Set the comment of an entry defined by its index - * @link http://php.net/manual/en/function.ziparchive-setcommentindex.php - * @param index int- * Index of the entry. - *
- * @param comment string- * The contents of the comment. - *
- * @return mixed Returns true on success or false on failure. - */ - public function setCommentIndex ($index, $comment) {} - - /** - * Set the comment of an entry defined by its name - * @link http://php.net/manual/en/function.ziparchive-setCommentName.php - * @param name string- * Name of the entry. - *
- * @param comment string- * The contents of the comment. - *
- * @return mixed Returns true on success or false on failure. - */ - public function setCommentName ($name, $comment) {} - - /** - * Returns the comment of an entry using the entry index - * @link http://php.net/manual/en/function.ziparchive-getcommentindex.php - * @param index int- * Index of the entry - *
- * @param flags int[optional]- * If flags is set to ZIPARCHIVE::FL_UNCHANGED, the original unchanged - * comment is returned. - *
- * @return string the comment on success or false on failure. - */ - public function getCommentIndex ($index, $flags = null) {} - - /** - * Returns the comment of an entry using the entry name - * @link http://php.net/manual/en/function.ziparchive-getcommentname.php - * @param name string- * Name of the entry - *
- * @param flags int[optional]- * If flags is set to ZIPARCHIVE::FL_UNCHANGED, the original unchanged - * comment is returned. - *
- * @return string the comment on success or false on failure. - */ - public function getCommentName ($name, $flags = null) {} - - /** - * delete an entry in the archive using its index - * @link http://php.net/manual/en/function.ziparchive-deleteindex.php - * @param index int- * Index of the entry to delete. - *
- * @return bool Returns true on success or false on failure. - */ - public function deleteIndex ($index) {} - - /** - * delete an entry in the archive using its name - * @link http://php.net/manual/en/function.ziparchive-deletename.php - * @param name string- * Name of the entry to delete. - *
- * @return bool Returns true on success or false on failure. - */ - public function deleteName ($name) {} - - /** - * Get the details of an entry defined by its name. - * @link http://php.net/manual/en/function.ziparchive-statname.php - * @param name name- * Name of the entry - *
- * @param flags int[optional]- * The flags argument specifies how the name lookup should be done. - * Also, ZIPARCHIVE::FL_UNCHANGED may be ORed to it to request - * information about the original file in the archive, - * ignoring any changes made. - *
- * ZIPARCHIVE::FL_NOCASE - *
- * @return mixed an array containing the entry details or false on failure. - */ - public function statName ($name, $flags = null) {} - - /** - * Get the details of an entry defined by its index. - * @link http://php.net/manual/en/function.ziparchive-statindex.php - * @param index int- * Index of the entry - *
- * @param flags int[optional]- * ZIPARCHIVE::FL_UNCHANGED may be ORed to it to request - * information about the original file in the archive, - * ignoring any changes made. - *
- * @return mixed an array containing the entry details or false on failure. - */ - public function statIndex ($index, $flags = null) {} - - /** - * Returns the index of the entry in the archive - * @link http://php.net/manual/en/function.ziparchive-locatename.php - * @param name string- * The name of the entry to look up - *
- * @param flags int[optional]- * The function returns the index of the file named fname in - * archive. The flags are specified by ORing the following values, - * or 0 for none of them. - *
- * ZIPARCHIVE::FL_NOCASE - *
- * @return mixed the index of the entry on success or false on failure. - */ - public function locateName ($name, $flags = null) { - if(!$this->zip_is_open){ - return false; - } - $noDir = ($flags & self::FL_NODIR) ? true:false; - $noCase = ($flags & self::FL_NOCASE) ? true:false; - - $loopFile = ($noDir) ? basename($name) : $name ; - if($noCase){ - $search = strtolower($search); - } - foreach($this->fileIndex as $ind => $fileRelPath){ - $loopFile = ($noDir) ? basename($fileRelPath) : $fileRelPath ; - if($noCase){ - $loopFile = strtolower($loopFile); - } - if( $loopFile == $search ){ - return $ind; - } - } - } - - /** - * Returns the name of an entry using its index - * @link http://php.net/manual/en/function.ziparchive-getnameindex.php - * @param index int- * Index of the entry. - *
- * @return string the name on success or false on failure. - */ - public function getNameIndex ($index) { - if(!$this->zip_is_open){ - return false; - } - if(! is_set($this->fileIndex[$index]) ){ - return false; - } - return $this->fileIndex[$index]; - } - - /** - * Revert all global changes done in the archive. - * @link http://php.net/manual/en/function.ziparchive-unchangearchive.php - * @return mixed Returns true on success or false on failure. - */ - public function unchangeArchive () {} - - /** - * Undo all changes done in the archive. - * @link http://php.net/manual/en/function.ziparchive-unchangeall.php - * @return mixed Returns true on success or false on failure. - */ - public function unchangeAll () {} - - /** - * Revert all changes done to an entry at the given index. - * @link http://php.net/manual/en/function.ziparchive-unchangeindex.php - * @param index int- * Index of the entry. - *
- * @return mixed Returns true on success or false on failure. - */ - public function unchangeIndex ($index) {} - - /** - * Revert all changes done to an entry with the given name. - * @link http://php.net/manual/en/function.ziparchive-unchangename.php - * @param name string- * Name of the entry. - *
- * @return mixed Returns true on success or false on failure. - */ - public function unchangeName ($name) {} - - /** - * Extract the archive contents - * @link http://php.net/manual/en/function.ziparchive-extractto.php - * @param destination string- * Location where to extract the files. - *
- * @param entries mixed[optional]- * The entries to extract. It accepts either a single entry name or - * an array of names. - *
- * @return mixed Returns true on success or false on failure. - */ - public function extractTo ($destination, $entries = null) { - if(!$this->zip_is_open){ - return false; - } - return $this->__extractTo($this->zipFilePath, $destination, $entries); - } - - private function __extractTo($zip_path, $destination, $entries = null) { - $return_value=0; - $output = array(); - - //determine list of files to extract - $list = ""; - if( is_string($entries) ){ - $list = "'$entries'"; - } - if(is_array($entries)){ - $list = "'".implode("' '", $entries)."'"; - } - - exec(self::$unzip_exec." -o {$zip_path} -d {$destination} {$list} 2>&1", $output, $return_value); - - if($return_value != 0){ - return false; - } - return true; - } - /** - * Returns the entry contents using its name. - * @link http://php.net/manual/en/function.ziparchive-getfromname.php - * @param name string- * Name of the entry - *
- * @param flags int[optional]- * The flags to use to open the archive. the following values may - * be ORed to it. - *
- * ZIPARCHIVE::FL_UNCHANGED - *
- * @return mixed the contents of the entry on success or false on failure. - */ - public function getFromName ($name, $flags = null) { - if(!$this->zip_is_open){ - return false; - } - return @file_get_contents($this->tempDirPath .DIRECTORY_SEPARATOR. $name ); - } - - /** - * Returns the entry contents using its index. - * @link http://php.net/manual/en/function.ziparchive-getfromindex.php - * @param index int- * Index of the entry - *
- * @param flags int[optional]- * The flags to use to open the archive. the following values may - * be ORed to it. - *
- * ZIPARCHIVE::FL_UNCHANGED - *
- * @return mixed the contents of the entry on success or false on failure. - */ - public function getFromIndex ($index, $flags = null) { - if(!$this->zip_is_open){ - return false; - } - $localFilePath = $this->getNameIndex($index); - if($localFilePath === false){ - return false; - } - return $this->getFromName($localFilePath); - } - - /** - * Get a file handler to the entry defined by its name (read only). - * @link http://php.net/manual/en/function.ziparchive-getstream.php - * @param name string- * The name of the entry to use. - *
- * @return resource a file pointer (resource) on success or false on failure. - */ - public function getStream ($name) {} - - /** - * - * @param $dir_path absolute path to zip directory - */ - private function __indexDirRec($dir_path){ - $dirEntries = scandir($dir_path); - - foreach($dirEntries as $dirEntriy){ - if( $dirEntriy == "." || $dirEntriy == ".."){ - continue; - } - $subject = $dir_path .DIRECTORY_SEPARATOR. $dirEntriy; - - //if this is directory then index its contents - if( is_dir($subject) ){ - $this->__indexDirRec($subject); - }else{ - //save path as relative path inside zip - $this->fileIndex[] = str_replace($this->tempDirPath.DIRECTORY_SEPARATOR, "", $subject); - } - } - } -} - -ZipArchive::setup(); //try to find locations of zip/unzip binaries - -/** - * Open a ZIP file archive - * @link http://php.net/manual/en/function.zip-open.php - * @param filename string- * The file name of the ZIP archive to open. - *
- * @return mixed a resource handle for later use with - * zip_read and zip_close - * or returns the number of error if filename does not - * exist or in case of other error. - */ -function zip_open ($filename) {} - -/** - * Close a ZIP file archive - * @link http://php.net/manual/en/function.zip-close.php - * @param zip resource- * A ZIP file previously opened with zip_open. - *
- * @return void - */ -function zip_close ($zip) {} - -/** - * Read next entry in a ZIP file archive - * @link http://php.net/manual/en/function.zip-read.php - * @param zip resource- * A ZIP file previously opened with zip_open. - *
- * @return mixed a directory entry resource for later use with the - * zip_entry_... functions or false if - * there's no more entries to read or number of error in case of other error. - */ -function zip_read ($zip) {} - -/** - * Open a directory entry for reading - * @link http://php.net/manual/en/function.zip-entry-open.php - * @param zip resource- * A valid resource handle returned by zip_open. - *
- * @param zip_entry resource- * A directory entry returned by zip_read. - *
- * @param mode string[optional]- * Any of the modes specified in the documentation of - * fopen. - *
- *- * Currently, mode is ignored and is always - * "rb". This is due to the fact that zip support - * in PHP is read only access. - *
- * @return bool Returns true on success or false on failure. - * - *- * Unlike fopen and other similar functions, - * the return value of zip_entry_open only - * indicates the result of the operation and is not needed for - * reading or closing the directory entry. - */ -function zip_entry_open ($zip, $zip_entry, $mode = null) {} - -/** - * Close a directory entry - * @link http://php.net/manual/en/function.zip-entry-close.php - * @param zip_entry resource
- * A directory entry previously opened zip_entry_open. - *
- * @return bool Returns true on success or false on failure. - */ -function zip_entry_close ($zip_entry) {} - -/** - * Read from an open directory entry - * @link http://php.net/manual/en/function.zip-entry-read.php - * @param zip_entry resource- * A directory entry returned by zip_read. - *
- * @param length int[optional]- * The number of bytes to return. If not specified, this function will - * attempt to read 1024 bytes. - *
- *- * This should be the uncompressed length you wish to read. - *
- * @return string the data read, or false if the end of the file is - * reached. - */ -function zip_entry_read ($zip_entry, $length = null) {} - -/** - * Retrieve the actual file size of a directory entry - * @link http://php.net/manual/en/function.zip-entry-filesize.php - * @param zip_entry resource- * A directory entry returned by zip_read. - *
- * @return int The size of the directory entry. - */ -function zip_entry_filesize ($zip_entry) {} - -/** - * Retrieve the name of a directory entry - * @link http://php.net/manual/en/function.zip-entry-name.php - * @param zip_entry resource- * A directory entry returned by zip_read. - *
- * @return string The name of the directory entry. - */ -function zip_entry_name ($zip_entry) {} - -/** - * Retrieve the compressed size of a directory entry - * @link http://php.net/manual/en/function.zip-entry-compressedsize.php - * @param zip_entry resource- * A directory entry returned by zip_read. - *
- * @return int The compressed size. - */ -function zip_entry_compressedsize ($zip_entry) {} - -/** - * Retrieve the compression method of a directory entry - * @link http://php.net/manual/en/function.zip-entry-compressionmethod.php - * @param zip_entry resource- * A directory entry returned by zip_read. - *
- * @return string The compression method. - */ -function zip_entry_compressionmethod ($zip_entry) {} - diff --git a/admin/inc/ajax.php b/admin/inc/ajax.php deleted file mode 100644 index f74fe75..0000000 --- a/admin/inc/ajax.php +++ /dev/null @@ -1,76 +0,0 @@ -'; - foreach ($templates as $file) { - $extension=pathinfo($file,PATHINFO_EXTENSION); - if (in_array($extension, $allowed_extensions)){ - $filename=pathinfo($file,PATHINFO_BASENAME); - $filenamefull=substr(strstr($file,'/theme/'.$TEMPLATE.'/'),strlen('/theme/'.$TEMPLATE.'/')); - if ($TEMPLATE_FILE == $filename){ - $sel="selected"; - } else { - $sel=""; - } - if ($filename == 'template.php'){ - $templatename=i18n_r('DEFAULT_TEMPLATE'); - } else { - $templatename=$filenamefull; - } - $theme_templates .= ''; - } - } - - $theme_templates .= ""; - - echo $theme_templates; -} -?> \ No newline at end of file diff --git a/admin/inc/api.class.php b/admin/inc/api.class.php deleted file mode 100644 index 9e1c8ce..0000000 --- a/admin/inc/api.class.php +++ /dev/null @@ -1,178 +0,0 @@ -status == 'true') { - if ( (string)$appid_file->key == (string)$this->xml->key) { - return true; - } else { - $message = array('status' => 'error', 'message' => i18n_r('API_ERR_AUTHFAILED')); - echo json_encode($message); - } - } else { - $message = array('status' => 'error', 'message' => i18n_r('API_ERR_AUTHDISABLED')); - echo json_encode($message); - } - } - - public function add_data($array) { - $this->xml = $array; - } - - /* - * Read Page - * - * @return json - */ - public function page_read() { - if($this->auth()) { - $id = (string)$this->xml->data->slug; - if (file_exists(GSDATAPAGESPATH.$id.'.xml')) { - $page = getXML(GSDATAPAGESPATH.$id.'.xml'); - $page->content = strip_decode($page->content); - $page->metak = strip_decode($page->metak); - $page->metad = strip_decode($page->metad); - $page->title = strip_decode($page->title); - $wrapper = array('status' => 'success', 'message' => 'page_read ok', 'response' => $page); - return json_encode($wrapper); - } else { - $error = array('status' => 'error', 'message' => sprintf(i18n_r('API_ERR_NOPAGE'), $id)); - return json_encode($error); - } - } - } - - /* - * Read Settings - * - * @return json - */ - public function settings_read() { - if($this->auth()) { - $settings = getXML(GSDATAOTHERPATH.'website.xml'); - $wrapper = array('status' => 'success', 'message' => 'settings_read ok', 'response' => $settings); - return json_encode($wrapper); - } - } - - /* - * Read All Pages - * - * @return json - */ - public function all_pages_read() { - if($this->auth()) { - $pages = get_available_pages(); - $wrapper = array('status' => 'success', 'message' => 'all_pages_read ok', 'response' => $pages); - return json_encode($wrapper); - } - } - - /* - * Upload File - * - * @return bool - */ - public function file_upload() { - if($this->auth()) { - - $patho = (string)$this->xml->data->path; - $path = tsl(GSDATAUPLOADPATH . $patho); - - } - } - - /* - * Save Page - * - * @return bool - */ - public function page_save() { - if($this->auth()) { - $id = (string)$this->xml->data->slug; - $thisfile = GSDATAPAGESPATH.$id.'.xml'; - if (file_exists($thisfile)) { - $page = getXML($thisfile); - $page->content = safe_slash_html($this->xml->data->content); - $page->title = safe_slash_html($this->xml->data->title); - $page->pubDate = date('r'); - $bakfile = GSBACKUPSPATH."pages/". $id .".bak.xml"; - copy($thisfile, $bakfile); - $status = XMLsave($page, $thisfile); - if ($status) { - touch($thisfile); - $wrapper = array('status' => 'success', 'message' => 'page_save ok', 'response' => $page); - } else { - $wrapper = array('status' => 'error', 'message' => 'There was an error saving your page'); - } - return json_encode($wrapper); - } else { - $error = array('status' => 'error', 'message' => sprintf(i18n_r('API_ERR_NOPAGE'), $id)); - return json_encode($error); - } - } - } - - /* - * Read Files - * - * @return json - */ - public function all_files_read() { - if($this->auth()) { - $patho = (string)$this->xml->data->path; - $path = tsl(GSDATAUPLOADPATH . $patho); - $filesArray = array(); - $count =0; - global $SITEURL; - - $filenames = getFiles($path); - if (count($filenames) != 0) { - foreach ($filenames as $file) { - if ($file == "." || $file == ".." || $file == ".htaccess" ){ - // not a upload file - } else { - - $filesArray[$count]['name'] = $file; - if (is_dir($path . $file)) { - $filesArray[$count]['type'] = 'folder'; - } else { - $filesArray[$count]['type'] = 'file'; - $filesArray[$count]['url'] = tsl($SITEURL.'data/uploads/'.$patho).$file; - $ext = pathinfo($file,PATHINFO_EXTENSION); - $extention = get_FileType($ext); - $filesArray[$count]['category'] = $extention; - clearstatcache(); - $ss = stat($path . $file); - $filesArray[$count]['date'] = date('c',$ss['ctime']); - $filesArray[$count]['size'] = $ss['size']; - } - - } - $count++; - } - } - $filesArray = subval_sort($filesArray, 'name'); - $filesArray = subval_sort($filesArray, 'type'); - $wrapper = array('status' => 'success', 'message' => 'all_files_read ok', 'response' => $filesArray); - return json_encode($wrapper); - } - } - -} // end of class -?> \ No newline at end of file diff --git a/admin/inc/api.plugin.php b/admin/inc/api.plugin.php deleted file mode 100644 index 52f5afe..0000000 --- a/admin/inc/api.plugin.php +++ /dev/null @@ -1,104 +0,0 @@ -*
- - ','?','[',']','\\',';',"'",',','/','*','+','~','`','=','.'); - $code_entities_replace = array('','-','-','','','','','','','','','','','','','','','','','','','','','','','',''); - $text = str_replace($code_entities_match, $code_entities_replace, $text); - $text = urlencode($text); - $text = str_replace('--','-',$text); - $text = rtrim($text, "-"); - return $text; -} - -/** - * Clean Image Name - * - * Mirror image of Clean URL, but it allows periods so file extentions still work - * - * @since 2.0 - * - * @param string $text - * @return string - */ -function clean_img_name($text) { - $text = strip_tags(lowercase($text)); - $code_entities_match = array(' ?',' ','--','"','!','#','$','%','^','&','*','(',')','+','{','}','|',':','"','<','>','?','[',']','\\',';',"'",',','/','*','+','~','`','='); - $code_entities_replace = array('','-','-','','','','','','','','','','','','','','','','','','','','','',''); - $text = str_replace($code_entities_match, $code_entities_replace, $text); - $text = urlencode($text); - $text = str_replace('--','-',$text); - $text = str_replace('%40','@',$text); // ensure @ is not encoded - $text = rtrim($text, "-"); - return $text; -} - -/** - * 7bit Text Converter - * - * Converts a string to a different encoding format - * - * @since 1.0 - * - * @param string $text - * @param string $from_enc - * @return string - */ -function to7bit($text,$from_enc="UTF-8") { - if (function_exists('mb_convert_encoding')) { - $text = mb_convert_encoding($text,'HTML-ENTITIES',$from_enc); - } else { - $text = htmlspecialchars_decode(utf8_decode(htmlentities($text, ENT_COMPAT, 'utf-8', false))); - } - $text = preg_replace( - array('/ß/','/&(..)lig;/', - '/&([aouAOU])uml;/','/&(.)[^;]*;/'), - array('ss',"$1","$1".'e',"$1"), - $text); - return $text; -} - - -/** - * Formats Email to HTML Style - * - * @since 3.1 - * - * @param string $message - * @return string - */ -function email_template($message) { - $data = ' - - - - - - - -
-
|
-
/'.$GSADMIN.'/install.php
, /'.$GSADMIN.'/setup.php
or /'.$GSADMIN.'/update.php
');
- }
- }
-
-}
-
-/**
- * Include other files depending if they are needed or not
- */
-include_once(GSADMININCPATH.'cookie_functions.php');
-if(isset($load['plugin']) && $load['plugin']){
- # remove the pages.php plugin if it exists.
- if (file_exists(GSPLUGINPATH.'pages.php')) {
- unlink(GSPLUGINPATH.'pages.php');
- }
- include_once(GSADMININCPATH.'plugin_functions.php');
- if(get_filename_id()=='settings' || get_filename_id()=='load') {
- /* this core plugin only needs to be visible when you are viewing the
- settings page since that is where its sidebar item is. */
- if (defined('GSEXTAPI') && GSEXTAPI==1) {
- include_once('api.plugin.php');
- }
- }
- # include core plugin for page caching
- include_once('caching_functions.php');
-
- # main hook for common.php
- exec_action('common');
-
-}
-if(isset($load['login']) && $load['login']){ include_once(GSADMININCPATH.'login_functions.php'); }
-?>
diff --git a/admin/inc/configuration.php b/admin/inc/configuration.php
deleted file mode 100644
index fd50c5a..0000000
--- a/admin/inc/configuration.php
+++ /dev/null
@@ -1,31 +0,0 @@
-
diff --git a/admin/inc/cookie_functions.php b/admin/inc/cookie_functions.php
deleted file mode 100644
index 3fe0e1c..0000000
--- a/admin/inc/cookie_functions.php
+++ /dev/null
@@ -1,101 +0,0 @@
-
\ No newline at end of file
diff --git a/admin/inc/image.class.php b/admin/inc/image.class.php
deleted file mode 100644
index 3ea4639..0000000
--- a/admin/inc/image.class.php
+++ /dev/null
@@ -1,212 +0,0 @@
-image_type == 1) && !function_exists('imagegif')) $this->image_type = 3;
-
- switch ($this->image_type) {
- case 1:
- if ($this->save_to_file) {
- header("Content-type: image/gif");
- $res = ImageGIF($im,$filename);
- $res = ImageGIF($im,NULL);
- }
- else {
- header("Content-type: image/gif");
- $res = ImageGIF($im,$filename);
- $res = ImageGIF($im,NULL);
- }
- break;
- case 2:
- if ($this->save_to_file) {
- header("Content-type: image/jpeg");
- $res = ImageJPEG($im,$filename,$this->quality);
- $res = ImageJPEG($im,NULL,$this->quality);
- }
- else {
- header("Content-type: image/jpeg");
- $res = ImageJPEG($im,$filename,$this->quality);
- $res = ImageJPEG($im,NULL,$this->quality);
- }
- break;
- case 3:
- if (PHP_VERSION >= '5.1.2') {
- // Convert to PNG quality.
- // PNG quality: 0 (best quality, bigger file) to 9 (worst quality, smaller file)
- $quality = 9 - min( round($this->quality / 10), 9 );
- if ($this->save_to_file) {
- header("Content-type: image/png");
- $res = ImagePNG($im, $filename, $quality);
- $res = ImagePNG($im, NULL, $quality);
- }
- else {
- header("Content-type: image/png");
- $res = ImagePNG($im, $filename, $quality);
- $res = ImagePNG($im, NULL, $quality);
- }
- }
- else {
- if ($this->save_to_file) {
- header("Content-type: image/png");
- $res = ImagePNG($im, $filename);
- $res = ImagePNG($im);
- }
- else {
- header("Content-type: image/png");
- $res = ImagePNG($im, $filename);
- $res = ImagePNG($im);
- }
- }
- break;
- }
-
- return $res;
-
- }
-
- function ImageCreateFromType($type,$filename) {
- $im = null;
- switch ($type) {
- case 1:
- $im = ImageCreateFromGif($filename);
- break;
- case 2:
- $im = ImageCreateFromJpeg($filename);
- break;
- case 3:
- $im = ImageCreateFromPNG($filename);
- break;
- }
- return $im;
- }
-
- // generate thumb from image and save it
- function GenerateThumbFile($from_name, $to_name) {
-
- // if src is URL then download file first
- $temp = false;
- if (substr($from_name,0,7) == 'http://') {
- $tmpfname = tempnam("tmp/", "TmP-");
- $temp = @fopen($tmpfname, "w");
- if ($temp) {
- @fwrite($temp, @file_get_contents($from_name)) or die("Cannot download image");
- @fclose($temp);
- $from_name = $tmpfname;
- }
- else {
- die("Cannot create temp file");
- }
- }
-
- // check if file exists
- if (!file_exists($from_name)) die("Source image does not exist!");
-
- // get source image size (width/height/type)
- // orig_img_type 1 = GIF, 2 = JPG, 3 = PNG
- list($orig_x, $orig_y, $orig_img_type, $img_sizes) = @GetImageSize($from_name);
-
- // cut image if specified by user
- if ($this->cut_x > 0) $orig_x = min($this->cut_x, $orig_x);
- if ($this->cut_y > 0) $orig_y = min($this->cut_y, $orig_y);
-
- // should we override thumb image type?
- $this->image_type = ($this->image_type != -1 ? $this->image_type : $orig_img_type);
-
- // check for allowed image types
- if ($orig_img_type < 1 or $orig_img_type > 3) die("Image type not supported");
-
- if ($orig_x > $this->max_x or $orig_y > $this->max_y) {
-
- // resize
- $per_x = $orig_x / $this->max_x;
- $per_y = $orig_y / $this->max_y;
- if ($per_y > $per_x) {
- $this->max_x = $orig_x / $per_y;
- }
- else {
- $this->max_y = $orig_y / $per_x;
- }
-
- }
- else {
- // keep original sizes, i.e. just copy
- if ($this->save_to_file) {
- @copy($from_name, $to_name);
- }
- else {
- switch ($this->image_type) {
- case 1:
- header("Content-type: image/gif");
- readfile($from_name);
- break;
- case 2:
- header("Content-type: image/jpeg");
- readfile($from_name);
- break;
- case 3:
- header("Content-type: image/png");
- readfile($from_name);
- break;
- }
- }
- return;
- }
-
- if ($this->image_type == 1) {
- // should use this function for gifs (gifs are palette images)
- $ni = imagecreate($this->max_x, $this->max_y);
- }
- else {
- // Create a new true color image
- $ni = ImageCreateTrueColor($this->max_x,$this->max_y);
- }
-
- // Fill image with white background (255,255,255)
- $white = imagecolorallocate($ni, 255, 255, 255);
- imagefilledrectangle( $ni, 0, 0, $this->max_x, $this->max_y, $white);
- // Create a new image from source file
- $im = $this->ImageCreateFromType($orig_img_type,$from_name);
- // Copy the palette from one image to another
- imagepalettecopy($ni,$im);
- // Copy and resize part of an image with resampling
- imagecopyresampled(
- $ni, $im, // destination, source
- 0, 0, 0, 0, // dstX, dstY, srcX, srcY
- $this->max_x, $this->max_y, // dstW, dstH
- $orig_x, $orig_y); // srcW, srcH
-
- // save thumb file
- $this->SaveImage($ni, $to_name);
-
- if($temp) {
- unlink($tmpfname); // this removes the file
- }
-
- }
-
-}
-
-?>
\ No newline at end of file
diff --git a/admin/inc/imagemanipulation.php b/admin/inc/imagemanipulation.php
deleted file mode 100644
index db65beb..0000000
--- a/admin/inc/imagemanipulation.php
+++ /dev/null
@@ -1,312 +0,0 @@
-0,
- 'targety'=>0,
- 'quality'=>75);
-
- /**
- * A boolean value to detect if an image has not been created. This
- * can be used to validate that an image is viable before trying
- * resize or crop.
- *
- * @var boolean
- */
- public $imageok = false;
-
- /**
- * Contructor method. Will create a new image from the target file.
- * Accepts an image filename as a string. Method also works out how
- * big the image is and stores this in the $image array.
- *
- * @param string $imgFile The image filename.
- */
- public function ImageManipulation($imgfile)
- {
- //detect image format
- $this->image["format"] = preg_replace("/.*\.(.*)$/", "\\1", $imgfile);
- $this->image["format"] = strtoupper($this->image["format"]);
-
- // convert image into usable format.
- if ( $this->image["format"] == "JPG" || $this->image["format"] == "JPEG" ) {
- //JPEG
- $this->image["format"] = "JPEG";
- $this->image["src"] = ImageCreateFromJPEG($imgfile);
- } elseif( $this->image["format"] == "PNG" ){
- //PNG
- $this->image["format"] = "PNG";
- $this->image["src"] = imagecreatefrompng($imgfile);
- } elseif( $this->image["format"] == "GIF" ){
- //GIF
- $this->image["format"] = "GIF";
- $this->image["src"] = ImageCreateFromGif($imgfile);
- } elseif ( $this->image["format"] == "WBMP" ){
- //WBMP
- $this->image["format"] = "WBMP";
- $this->image["src"] = ImageCreateFromWBMP($imgfile);
- } else {
- //DEFAULT
- return false;
- }
-
- // Image is ok
- $this->imageok = true;
-
- // Work out image size
- $this->image["sizex"] = imagesx($this->image["src"]);
- $this->image["sizey"] = imagesy($this->image["src"]);
- }
-
- /**
- * Sets the height of the image to be created. The width of the image
- * is worked out depending on the value of the height.
- *
- * @param int $height The height of the image.
- */
- public function setImageHeight($height=100)
- {
- //height
- $this->image["sizey_thumb"] = $height;
- $this->image["sizex_thumb"] = ($this->image["sizey_thumb"]/$this->image["sizey"])*$this->image["sizex"];
- }
-
- /**
- * Sets the width of the image to be created. The height of the image
- * is worked out depending on the value of the width.
- *
- * @param int $size The width of the image.
- */
- public function setImageWidth($width=100)
- {
- //width
- $this->image["sizex_thumb"] = $width;
- $this->image["sizey_thumb"] = ($this->image["sizex_thumb"]/$this->image["sizex"])*$this->image["sizey"];
- }
-
- /**
- * This method automatically sets the width and height depending
- * on the dimensions of the image up to a maximum value.
- *
- * @param int $size The maximum size of the image.
- */
- public function resize($size=100)
- {
- if ( $this->image["sizex"] >= $this->image["sizey"] ) {
- $this->image["sizex_thumb"] = $size;
- $this->image["sizey_thumb"] = ($this->image["sizex_thumb"]/$this->image["sizex"])*$this->image["sizey"];
- } else {
- $this->image["sizey_thumb"] = $size;
- $this->image["sizex_thumb"] = ($this->image["sizey_thumb"]/$this->image["sizey"])*$this->image["sizex"];
- }
- }
-
- /**
- * This method sets the cropping values of the image. Be sure
- * to set the height and with of the image if you want the
- * image to be a certain size after cropping.
- *
- * @param int $x The x coordinates to start cropping from.
- * @param int $y The y coordinates to start cropping from.
- * @param int $w The width of the crop from the x and y coordinates.
- * @param int $h The height of the crop from the x and y coordinates.
- */
- public function setCrop($x, $y, $w, $h)
- {
- $this->image["targetx"] = $x;
- $this->image["targety"] = $y;
- $this->image["sizex"] = $w;
- $this->image["sizey"] = $h;
- }
-
- /**
- * Sets the JPEG output quality.
- *
- * @param int $quality The quality of the JPEG image.
- */
- public function setJpegQuality($quality=75)
- {
- //jpeg quality
- $this->image["quality"] = $quality;
- }
-
- /**
- * Shows the image to a browser. Sets the correct image format in a header.
- */
- public function show()
- {
- //show thumb
- header("Content-Type: image/".$this->image["format"]);
-
- $this->createResampledImage();
-
- if ( $this->image["format"]=="JPG" || $this->image["format"]=="JPEG" ) {
- //JPEG
- imageJPEG($this->image["des"], "", $this->image["quality"]);
- } elseif ( $this->image["format"] == "PNG" ) {
- //PNG
- imagePNG($this->image["des"]);
- } elseif ( $this->image["format"] == "GIF" ) {
- //GIF
- imageGIF($this->image["des"]);
- } elseif ( $this->image["format"] == "WBMP" ) {
- //WBMP
- imageWBMP($this->image["des"]);
- }
- }
-
- /**
- * Private method to run the imagecopyresampled() function with the parameters that have been set up.
- * This method is used by the save() and show() methods.
- */
- private function createResampledImage()
- {
- /* change ImageCreateTrueColor to ImageCreate if your GD not supported ImageCreateTrueColor function*/
- if ( isset($this->image["sizex_thumb"]) && isset($this->image["sizey_thumb"]) ) {
- $this->image["des"] = ImageCreateTrueColor($this->image["sizex_thumb"], $this->image["sizey_thumb"]);
- imagecopyresampled($this->image["des"], $this->image["src"], 0, 0, $this->image["targetx"], $this->image["targety"], $this->image["sizex_thumb"], $this->image["sizey_thumb"], $this->image["sizex"], $this->image["sizey"]);
- } else {
- $this->image["des"] = ImageCreateTrueColor($this->image["sizex"], $this->image["sizey"]);
- imagecopyresampled($this->image["des"], $this->image["src"], 0, 0, $this->image["targetx"], $this->image["targety"], $this->image["sizex"], $this->image["sizey"], $this->image["sizex"], $this->image["sizey"]);
- }
- }
-
- /**
- * Saves the image to a given filename, if no filename is given then a default is created.
- *
- * @param string $save The new image filename.
- */
- public function save($save="")
- {
- //save thumb
- if ( empty($save) ) {
- $save = strtolower("./thumb.".$this->image["format"]);
- }
- header("Content-Type: image/".$this->image["format"]);
- $this->createResampledImage();
-
- if ( $this->image["format"] == "JPG" || $this->image["format"] == "JPEG" ) {
- //JPEG
- imageJPEG($this->image["des"], $save, $this->image["quality"]);
- } elseif ( $this->image["format"] == "PNG" ) {
- //PNG
- imagePNG($this->image["des"], $save);
- } elseif ( $this->image["format"] == "GIF" ) {
- //GIF
- imageGIF($this->image["des"], $save);
- } elseif ( $this->image["format"] == "WBMP" ) {
- //WBMP
- imageWBMP($this->image["des"], $save);
- }
-
- header("Content-Type: text/html");
- }
-}
\ No newline at end of file
diff --git a/admin/inc/logging.class.php b/admin/inc/logging.class.php
deleted file mode 100644
index 81303b7..0000000
--- a/admin/inc/logging.class.php
+++ /dev/null
@@ -1,134 +0,0 @@
-add('field','value'); // add record entries to log record
- * $class->save(); // write log record to file
- * $class->clear(); // removes log file
- */
-
-class GS_Logging_Class {
-
- private $_xml;
- private $_xmlfile;
- private $_entry;
-
- function __construct($filename,$logdefaults=true) {
- // check filename, must be .log
-
- if($this->validFilename($filename)){
- $this->_xmlfile = GSDATAOTHERPATH.'logs/'.$filename;
- if ( file_exists($this->_xmlfile) ) {
- $xml = file_get_contents($this->_xmlfile);
- if($xml) $this->_xml = simplexml_load_string($xml, 'SimpleXMLExtended', LIBXML_NOCDATA);
- else $this->_xml = new SimpleXMLExtended('/data
, /backups
folders & sub-folders and retry.",
-"EMAIL_COMPLETE" => "Setup Complete",
-"EMAIL_USERNAME" => "Your username is",
-"EMAIL_PASSWORD" => "Your new password is",
-"EMAIL_LOGIN" => "Login here",
-"EMAIL_THANKYOU" => "Thank you for using",
-"NOTE_REGISTRATION" => "Your registration information has been sent to",
-"NOTE_REGERROR" => "Error: There was a problem sending out the registration information via email. Please make note of the password below",
-"NOTE_USERNAME" => "Your username is",
-"NOTE_PASSWORD" => "and your password is",
-"INSTALLATION" => "Installation",
-"LABEL_WEBSITE" => "Website Name",
-"LABEL_BASEURL" => "Website URL",
-"LABEL_SUGGESTION" => "Our suggestion is",
-"LABEL_USERNAME" => "Username",
-"LABEL_DISPNAME" => "Display Name",
-"LABEL_EMAIL" => "Email Address",
-"LABEL_INSTALL" => "Install Now!",
-"SELECT_LANGUAGE" => "Select your language",
-"CONTINUE_SETUP" => "Continue with Setup",
-"DOWNLOAD_LANG" => "Download Languages",
-"SITE_UPDATED" => "Your site has been updated",
-"SERVICE_UNAVAILABLE" => "This page is temporarily unavailable",
-
-/*
- * For: pages.php
-*/
-"MENUITEM_SUBTITLE" => "menu item",
-"HOMEPAGE_SUBTITLE" => "homepage",
-"PRIVATE_SUBTITLE" => "private",
-"EDITPAGE_TITLE" => "Edit Page",
-"VIEWPAGE_TITLE" => "View Page",
-"DELETEPAGE_TITLE" => "Delete Page",
-"PAGE_MANAGEMENT" => "Page Management",
-"TOGGLE_STATUS" => "Toggle Status",
-"TOTAL_PAGES" => "total pages",
-"ALL_PAGES" => "Pages",
-
-/*
- * For: edit.php
-*/
-"PAGE_NOTEXIST" => "The requested page does not exist",
-"BTN_SAVEPAGE" => "Save Page",
-"BTN_SAVEUPDATES" => "Save Updates",
-"DEFAULT_TEMPLATE" => "Default Template",
-"NONE" => "None",
-"PAGE" => "Page",
-"NEW_PAGE" => "New Page",
-"PAGE_EDIT_MODE" => "Edit Page",
-"CREATE_NEW_PAGE" => "Add New Page",
-"VIEW" => "View",
-"PAGE_OPTIONS" => "Page Options",
-"SLUG_URL" => "Custom URL (Slug)",
-"TAG_KEYWORDS" => "Tags & Keywords",
-"PARENT_PAGE" => "Page Parent",
-"TEMPLATE" => "Page Template",
-"KEEP_PRIVATE" => "Page Visibility",
-"ADD_TO_MENU" => "Add this page to the menu",
-"PRIORITY" => "Priority",
-"MENU_TEXT" => "Menu Text",
-"LABEL_PAGEBODY" => "Page Body",
-"CANCEL" => "Cancel",
-"BACKUP_AVAILABLE" => "Backup Available",
-"MAX_FILE_SIZE" => "Max file size",
-"LAST_SAVED" => "Page last saved by %s on",
-"FILE_UPLOAD" => "File Upload",
-"OR" => "or",
-"SAVE_AND_CLOSE" => "Save & Close",
-"PAGE_UNSAVED" => "Page has unsaved changes",
-
-/*
- * For: upload.php
-*/
-"ERROR_UPLOAD" => "There was a problem with the file upload",
-"FILE_SUCCESS_MSG" => "Success! File location",
-"FILE_MANAGEMENT" => "File Management",
-"UPLOADED_FILES" => "Uploaded Files",
-"SHOW_ALL" => "Show All",
-"VIEW_FILE" => "View File",
-"DELETE_FILE" => "Delete File",
-"TOTAL_FILES" => "total files & folders",
-
-/*
- * For: logout.php
-*/
-"MSG_LOGGEDOUT" => "You are now logged out.",
-
-/*
- * For: index.php
-*/
-"LOGIN" => "Login",
-"USERNAME" => "Username",
-"PASSWORD" => "Password",
-"FORGOT_PWD" => "Forgot your password?",
-"CONTROL_PANEL" => "Control Panel Login",
-
-/*
- * For: navigation.php
-*/
-"CURRENT_MENU" => "Current Menu",
-"NO_MENU_PAGES" => "There are no pages that are set to appear within the main menu",
-
-/*
- * For: theme-edit.php
-*/
-"TEMPLATE_FILE" => "Template file %s has successfully been updated!",
-"THEME_MANAGEMENT" => "Theme Management",
-"EDIT_THEME" => "Theme Editor",
-"EDITING_FILE" => "Editing File",
-"BTN_SAVECHANGES" => "Save Changes",
-"EDIT" => "Edit",
-
-/*
- * For: support.php
-*/
-"SETTINGS_UPDATED" => "Your settings have been updated",
-"UNDO" => "Undo",
-"SUPPORT" => "Support",
-"SETTINGS" => "Settings",
-"ERROR" => "Error",
-"BTN_SAVESETTINGS" => "Save Settings",
-"VIEW_FAILED_LOGIN" => "View Failed Login Attempts",
-
-
-/*
- * For: log.php
-*/
-"MSG_HAS_BEEN_CLR" => " has been cleared",
-"LOGS" => "Logs",
-"VIEWING" => "Viewing",
-"LOG_FILE" => "Log File",
-"CLEAR_ALL_DATA" => "Clear all data from",
-"CLEAR_THIS_LOG" => "Clear This Log",
-"LOG_FILE_ENTRY" => "LOG FILE ENTRY",
-"THIS_COMPUTER" => "This Computer",
-
-/*
- * For: backup-edit.php
-*/
-"BAK_MANAGEMENT" => "Backup Management",
-"ASK_CANCEL" => "Cancel", // 'c' is the accesskey identifier
-"ASK_RESTORE" => "Restore", // 'r' is the accesskey identifier
-"ASK_DELETE" => "Delete", // 'd' is the accesskey identifier
-"BACKUP_OF" => "Backup of",
-"PAGE_TITLE" => "Page Title",
-"YES" => "Yes",
-"NO" => "No",
-"DATE" => "Date",
-"PERMS" => "Perms",
-
-/*
- * For: components.php
-*/
-"COMPONENTS" => "Components",
-"DELETE_COMPONENT" => "Delete Component",
-"EDIT" => "Edit",
-"ADD_COMPONENT" => "Add Component", // 'a' is the accesskey identifier
-"SAVE_COMPONENTS" => "Save Components",
-
-/*
- * For: sitemap.php
-*/
-"SITEMAP_CREATED" => "Sitemap Created! We also successfully pinged 4 search engines of the update",
-"SITEMAP_ERRORPING" => "Sitemap Created, however there was an error pinging one or more of the search engines",
-"SITEMAP_ERROR" => "Your sitemap could not be generated",
-"SITEMAP_WAIT" => "Please Wait: Creating website sitemap",
-
-/*
- * For: theme.php
-*/
-"THEME_CHANGED" => "Your theme has been changed successfully",
-"CHOOSE_THEME" => "Choose Your Theme",
-"ACTIVATE_THEME" => "Activate Theme",
-"THEME_SCREENSHOT" => "Theme Screenshot",
-"THEME_PATH" => "Theme Folder Location",
-
-/*
- * For: resetpassword.php
-*/
-"RESET_PASSWORD" => "Reset Password",
-"YOUR_NEW" => "Your new",
-"PASSWORD_IS" => "password is",
-"ATTEMPT" => "Attempt",
-"MSG_PLEASE_EMAIL" => "Please enter the username registered on this system, and a new password will be sent to its email address.",
-"SEND_NEW_PWD" => "Send New Password",
-
-/*
- * For: settings.php
-*/
-"GENERAL_SETTINGS" => "General Settings",
-"WEBSITE_SETTINGS" => "Website Settings",
-"LOCAL_TIMEZONE" => "Local Timezone",
-"LANGUAGE" => "Language",
-"USE_FANCY_URLS" => "Use Fancy URLs - Requires that your host has mod_rewrite
enabled",
-"ENABLE_HTML_ED" => "Enable the HTML editor",
-"WARN_EMAILINVALID" => "WARNING: This email address does not look valid!",
-"ONLY_NEW_PASSWORD" => "Only provide a password below if you want to change your current one",
-"NEW_PASSWORD" => "New Password",
-"CONFIRM_PASSWORD" => "Confirm Password",
-"PASSWORD_NO_MATCH" => "Passwords do not match",
-"PERMALINK" => "Custom Permalink Structure",
-"MORE" => "more",
-"HELP" => "help",
-"FLUSHCACHE" => "Flush All Caches",
-"FLUSHCACHE-SUCCESS"=> "Caches Flushed Successfully",
-"DISPLAY_NAME" => "A name for public display that is not your username",
-
-/*
- * For: health-check.php
-*/
-"WEB_HEALTH_CHECK" => "Website Health Check",
-"VERSION" => "Version",
-"UPG_NEEDED" => "Upgrade Recommended",
-"CANNOT_CHECK" => "Upgrade Check Failed !",
-"LATEST_VERSION" => "Latest version installed",
-"SERVER_SETUP" => "Server Setup",
-"OR_GREATER_REQ" => "or greater is required",
-"OK" => "OK",
-"INSTALLED" => "Installed",
-"NOT_INSTALLED" => "Not Installed",
-"WARNING" => "Warning",
-"DATA_FILE_CHECK" => "Data File Integrity Check",
-"DIR_PERMISSIONS" => "Directory Permissions",
-"EXISTANCE" => "%s Existence",
-"MISSING_FILE" => "Missing file",
-"BAD_FILE" => "Bad file",
-"NO_FILE" => "No file",
-"GOOD_D_FILE" => "Good 'Deny' file",
-"GOOD_A_FILE" => "Good 'Allow' file",
-"CANNOT_DEL_FILE" => "Cannot Delete File",
-"DOWNLOAD" => "Download",
-"WRITABLE" => "Writable",
-"NOT_WRITABLE" => "Not Writable",
-
-/*
- * For: footer.php
-*/
-"POWERED_BY" => "Powered by",
-
-/*
- * For: backups.php
-*/
-"PAGE_BACKUPS" => "Page Backups",
-"ASK_DELETE_ALL" => "Delete All",
-"DELETE_ALL_BAK" => "Delete all backups?",
-"TOTAL_BACKUPS" => "total backups",
-
-/*
- * For: archive.php
-*/
-"SUCC_WEB_ARCHIVE" => "An archive of your website has been successfully created",
-"SUCC_WEB_ARC_DEL" => "The seleted archive has been successfully deleted",
-"WEBSITE_ARCHIVES" => "Website Archives",
-"ARCHIVE_DELETED" => "Archive deleted successfully",
-"CREATE_NEW_ARC" => "Create a New Archive",
-"ASK_CREATE_ARC" => "Create New Archive Now",
-"CREATE_ARC_WAIT" => "Please Wait: Creating website archive...",
-"DOWNLOAD_ARCHIVES" => "Download Archive",
-"DELETE_ARCHIVE" => "Delete Archive",
-"TOTAL_ARCHIVES" => "total archives",
-
-/*
- * For: include-nav.php
-*/
-"WELCOME" => "Welcome", // used as 'Welcome USERNAME!'
-"TAB_PAGES" => "Pages",
-"TAB_FILES" => "Files",
-"TAB_THEME" => "Theme",
-"TAB_BACKUPS" => "Backups",
-"PLUGINS_NAV" => "Plugins",
-"TAB_SETTINGS" => "Settings",
-"TAB_SUPPORT" => "Support",
-"TAB_LOGOUT" => "Logout",
-
-/*
- * For: sidebar-files.php
-*/
-"BROWSE_COMPUTER" => "Browse Your Computer",
-"UPLOAD" => "Upload",
-
-/*
- * For: sidebar-support.php
-*/
-"SIDE_SUPPORT_LOG" => "Support",
-"SIDE_HEALTH_CHK" => "Website Health Check",
-"SIDE_DOCUMENTATION"=> "Wiki Documentation",
-"SIDE_VIEW_LOG"=> "View Log",
-
-/*
- * For: sidebar-theme.php
-*/
-"SIDE_VIEW_SITEMAP" => "View Sitemap",
-"SIDE_GEN_SITEMAP" => "Generate Sitemap",
-"SIDE_COMPONENTS" => "Edit Components",
-"SIDE_EDIT_THEME" => "Edit Theme",
-"SIDE_CHOOSE_THEME" => "Choose Theme",
-
-/*
- * For: sidebar-pages.php
-*/
-"SIDE_CREATE_NEW" => "Create New Page",
-"SIDE_VIEW_PAGES" => "View All Pages",
-
-/*
- * For: sidebar-settings.php
-*/
-"SIDE_GEN_SETTINGS" => "General Settings",
-"SIDE_USER_PROFILE" => "User Profile",
-
-/*
- * For: sidebar-backups.php
-*/
-"SIDE_VIEW_BAK" => "View Page Backup",
-"SIDE_WEB_ARCHIVES" => "Website Archives",
-"SIDE_PAGE_BAK" => "Page Backups",
-
-/*
- * For: error_checking.php
-*/
-"ER_PWD_CHANGE" => "Don't forget to change your password from that random generated one you have now...",
-"ER_BAKUP_DELETED" => "The backup has been deleted for %s",
-"ER_REQ_PROC_FAIL" => "The requested process failed",
-"ER_YOUR_CHANGES" => "Your changes to %s have been saved",
-"ER_HASBEEN_REST" => "%s has been restored",
-"ER_HASBEEN_DEL" => "%s has been deleted",
-"ER_CANNOT_INDEX" => "You cannot change the URL of the index page",
-"ER_SETTINGS_UPD" => "Your settings have been updated",
-"ER_OLD_RESTORED" => "Your old settings have been restored",
-"ER_NEW_PWD_SENT" => "A new password has been sent to the email address provided",
-"ER_SENDMAIL_ERR" => "There was a problem sending the email. Please try again",
-"ER_FILE_DEL_SUC" => "File deleted successfully",
-"ER_PROBLEM_DEL" => "There was a problem deleting the file",
-"ER_COMPONENT_SAVE" => "Your components have been saved",
-"ER_COMPONENT_REST" => "Your components have been restored",
-"ER_CANCELLED_FAIL" => "Cancelled: This update has been cancelled",
-
-/*
- * For: changedata.php
-*/
-"CANNOT_SAVE_EMPTY" => "You cannot save a page with an empty title",
-"META_DESC" => "Meta Description",
-
-/*
- * For: template_functions.php
-*/
-"FTYPE_COMPRESSED" => "Compressed", //a file-type
-"FTYPE_VECTOR" => "Vector", //a file-type
-"FTYPE_FLASH" => "Flash", //a file-type
-"FTYPE_VIDEO" => "Video", //a file-type
-"FTYPE_AUDIO" => "Audio", //a file-type
-"FTYPE_WEB" => "Web", //a file-type
-"FTYPE_DOCUMENTS" => "Documents", //a file-type
-"FTYPE_SYSTEM" => "System", //a file-type
-"FTYPE_MISC" => "Misc", //a file-type
-"IMAGES" => "Images",
-
-/*
- * For: login_functions.php
-*/
-"FILL_IN_REQ_FIELD" => "Please fill in all the required fields",
-"LOGIN_FAILED" => "Login failed. Please double check your Username and Password",
-
-/*
- * For: Date Format
-*/
-"DATE_FORMAT" => "M j, Y", //please keep short
-"DATE_AND_TIME_FORMAT" => "F jS, Y - g:i A", //date and time
-
-/*
- * For: support.php
-*/
-"WELCOME_MSG" => "Thank you for choosing GetSimple as your content management system!",
-"WELCOME_P" => "GetSimple makes managing a website as simple as possible with its best-in-class user interface. We strive to keep the system easy enough for anyone to use, yet powerful enough for a developer to enable all the features that are needed.Some first steps that might be useful:
", -"GETTING_STARTED" => "Getting Started", - -/* - * For: image.php -*/ - -"CURRENT_THUMBNAIL" => "Current Thumbnail", -"RECREATE" => "recreate", -"CREATE_ONE" => "create one", -"IMG_CONTROl_PANEL" => "Image Control Panel", -"ORIGINAL_IMG" => "Original Image", -"CLIPBOARD_INSTR" => "Select All", -"CREATE_THUMBNAIL" => "Create Thumbnail", -"CROP_INSTR_NEW" => "ctrl-B or command-B for square", -"SELECT_DIMENTIONS" => "Selection Dimentions", -"HTML_ORIG_IMG" => "Original Image HTML", -"LINK_ORIG_IMG" => "Original Image Link", -"HTML_THUMBNAIL" => "Thumbnail HTML", -"LINK_THUMBNAIL" => "Thumbnail Link", -"HTML_THUMB_ORIG" => "Thumbnail-to-Image HTML", - -/* - * For: plugins.php -*/ - -"PLUGINS_MANAGEMENT"=> "Plugin Management", -"PLUGINS_INSTALLED" => "plugins installed", -"PLUGIN_DISABLED" => "Disabled Plugin", -"SHOW_PLUGINS" => "Installed Plugins", -"PLUGIN_NAME" => "Plugin", -"PLUGIN_DESC" => "Description", -"PLUGIN_VER" => "Version", -"PLUGIN_UPDATED" => "Plugin Updated", - - - -/*********************************************************************************** - * SINCE Version 3.0 -***********************************************************************************/ - -/* - * For: setup.php - */ - -"ROOT_HTACCESS_ERROR" => "Failed to create .htaccess in root! Please copy%s
to .htaccess
and change %s
to %s
",
-"REMOVE_TEMPCONFIG_ERROR" => "Failed to remove %s
! Please do it manually.",
-"MOVE_TEMPCONFIG_ERROR" => "Failed to rename %s
to %s
! Please do it manually.",
-"KILL_CANT_CONTINUE" => "Cannot continue. Please fix errors and try again.",
-"REFRESH" => "Refresh",
-"BETA"=> "Beta / Bleeding Edge",
-
-/*
- * Misc Cleanup Work
- */
-
-# new to 3.0
-"HOMEPAGE_DELETE_ERROR" => "You cannot delete your homepage", //deletefile
-"NO_ZIPARCHIVE" => "ZipArchive extension is not installed. Unable to continue", //zip
-"REDIRECT_MSG"=> "If your browser does not redirect you, click here", //basic
-"REDIRECT"=> "Redirect", //basic
-"DENIED"=> "Denied", //sitemap
-"DEBUG_MODE"=> "DEBUG MODE", //nav-include
-"DOUBLE_CLICK_EDIT"=> "Double Click to Edit", //components
-"THUMB_SAVED"=> "Thumbnail Saved", //image
-"EDIT_COMPONENTS" => "Edit Components", //components
-"REQS_MORE_INFO"=> "For more information on the required modules, visit the requirements page.", //install & health-check
-"SYSTEM_UPDATE" => "System Update", // update.php
-"AUTHOR" => "Author", //plugins.php
-"ENABLE" => "Activate", //plugins.php
-"DISABLE" => "Deactivate", //plugins.php
-"NO_THEME_SCREENSHOT" => "Your theme does not have a screenshot preview", //theme.php
-"UNSAVED_INFORMATION" => "You are about to leave this page and will lose any unsaved information.", //edit.php
-"BACK_TO_WEBSITE" => "Back to Website", //index & resetpassword
-"SUPPORT_FORUM" => "Support Forum", //support.php
-"FILTER" => "Filter", //pages.php
-"UPLOADIFY_BUTTON" => "Upload files and/or images...", //upload.php
-"FILE_BROWSER" => "File Browser", //filebrowser.php
-"SELECT_FILE" => "Select file", //filebrowser.php
-"CREATE_FOLDER" => "Create Folder", //upload.php
-"THUMBNAIL" => "Thumbnail", //filebrowser.php
-"ERROR_FOLDER_EXISTS" => "The folder you are trying to create already exists", //upload.php
-"FOLDER_CREATED" => "The new folder was successfully created: %s", //upload.php
-"ERROR_CREATING_FOLDER" => "There was an error creating the new folder", //upload.php
-"DELETE_FOLDER" => "Delete Folder", //upload.php
-"FILE_NAME" => "File Name", //multiple tr header rows
-"FILE_SIZE" => "Size", //multiple tr header rows
-"ARCHIVE_DATE" => "Archive Date", //archive.php
-"CKEDITOR_LANG" => "en", // edit.php ; set CKEditor language, don't forget to include CKEditor language file in translation zip
-
-# new to 3.1
-"XML_INVALID" => "XML Invalid", //template-functions.php
-"XML_VALID" => "XML Valid",
-"UPDATE_AVAILABLE" => "Update to", //plugins.php
-"STATUS" => "Status", //plugins.php
-"CLONE" => "Clone", //edit.php
-"CLONE_SUCCESS" => "Successfully created %s", //pages.php
-"COPY" => "Copy", //pages.php
-"CLONE_ERROR" => "There was a problem trying to clone %s", //pages.php
-"AUTOSAVE_NOTIFY" => 'Page autosaved at', //edit.php
-"MENU_MANAGER" => 'Menu Manager', //edit.php
-"GET_PLUGINS_LINK" => 'Download More Plugins',
-"SITEMAP_REFRESHED" => "Your sitemap has been refreshed", //edit.php
-"LOG_FILE_EMPTY" => "This log file is empty", //log.php
-"SHARE" => "Share", //footer.php
-"NO_PARENT" => "No Parent", //edit.php
-"REMAINING" => "characters remaining", //edit.php
-"NORMAL" => "Normal", //edit.php
-"ERR_CANNOT_DELETE" => "Cannot delete %s. Please do this manually.", //common.php
-"ADDITIONAL_ACTIONS" => "Other Actions", //edit.php
-"ITEMS" => "items", //upload.php
-"SAVE_MENU_ORDER" => "Save Menu Order", //menu-manager.php
-"MENU_MANAGER_DESC" => "Drag-and-drop the menu items around until you have the order you want, then click the 'Save Menu Order' button.", //menu-manager.php
-"MENU_MANAGER_SUCCESS" => "The new menu order has been saved", //menu-manager.php
-
-
-/*
- * For: api related pages
- */
-"API_ERR_MISSINGPARAM" => 'parameter data does not exist',
-"API_ERR_BADMETHOD" => 'method %s does not exist',
-"API_ERR_AUTHFAILED" => 'authentication failed',
-"API_ERR_AUTHDISABLED" => 'authentication disabled',
-"API_ERR_NOPAGE" => 'requested page %s does not exist',
-"API_CONFIGURATION" => 'API Configuration',
-"API_ENABLE" => 'Enable the API',
-"API_REGENKEY" => 'Regenerate Key',
-"API_DISCLAIMER" => "By enabling this API you are allowing any external application that has a copy of your key to have access to your website's data. Only share this key with applications you trust.",
-"API_REGEN_DISCLAIMER" => "When you regenerate your API Key, you will need to enter the new key into any external application using this API to connect to your website.",
-"API_CONFIRM" => "ARE YOU SURE?",
-
-
-"X" => "not translated",
-
-
-/*
- * Additions for 3.1
- */
-"DEBUG_CONSOLE" => 'Debug Console'
-
-);
-
-?>
diff --git a/admin/load-ajax.php b/admin/load-ajax.php
deleted file mode 100644
index c5e1289..0000000
--- a/admin/load-ajax.php
+++ /dev/null
@@ -1,3 +0,0 @@
-
-
-
-
-'.i18n_r('LOG_FILE_ENTRY').'
';
- foreach($log->children() as $child) {
- $name = $child->getName();
- echo ''. stripslashes(ucwords($name)) .': ';
-
- $d = $log->$name;
- $n = lowercase($child->getName());
- $ip_regex = '/^(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:[.](?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}$/';
- $url_regex = @"((https?|ftp|gopher|telnet|file|notes|ms-help):((//)|(\\\\))+[\w\d:#@%/;$()~_?\+-=\\\.&]*)";
-
-
- //check if its an url address
- if (do_reg($d, $url_regex)) {
- $d = ''.$d.'';
- }
-
- //check if its an ip address
- if (do_reg($d, $ip_regex)) {
- if ($d == $_SERVER['REMOTE_ADDR']) {
- $d = i18n_r('THIS_COMPUTER').' ('.$d.')';
- } else {
- $d = ''.$d.'';
- }
- }
-
- //check if its an email address
- if (check_email_address($d)) {
- $d = ''.$d.'';
- }
-
- //check if its a date
- if ($n === 'date') {
- $d = lngDate($d);
- }
-
- echo stripslashes($d);
- echo '
';
- }
- echo "
'.i18n_r('NO_MENU_PAGES').'.
'; - } - ?> - - - -- '. str_replace(array('',''), '', i18n_r('GET_PLUGINS_LINK')) .''; - } - ?> -
- -". cl($SITENAME) ." ". i18n_r('RESET_PASSWORD') ." ". i18n_r('ATTEMPT').'
'; - $message .= "". i18n_r('LABEL_USERNAME').": ". $USR."";
- $message .= "
". i18n_r('NEW_PASSWORD').": ". $random."";
- $message .= '
'. i18n_r('EMAIL_LOGIN') .': '.$SITEURL . $GSADMIN.'/
- - - - - - -
'.i18n_r('ER_PWD_CHANGE').'
'. sprintf(i18n_r('ER_BAKUP_DELETED'), $errid) .'
'.i18n_r('ERROR').': '.i18n_r('ER_REQ_PROC_FAIL').'
'; - if ($ptype == 'edit') { - echo sprintf(i18n_r('ER_YOUR_CHANGES'), $id) .'. '.i18n_r('UNDO').''; - } elseif ($ptype == 'restore') { - echo sprintf(i18n_r('ER_HASBEEN_REST'), $id); - } elseif ($ptype == 'delete') { - echo sprintf(i18n_r('ER_HASBEEN_DEL'), $errid) .'. '.i18n_r('UNDO').''; - } - echo '
'.sprintf(i18n_r('CLONE_SUCCESS'), ''.$errid.'').'.
'.i18n_r('ERROR').': '.i18n_r('ER_CANNOT_INDEX').'.
'.i18n_r('ERROR').': '. var_out($ptype) .'.
'.i18n_r('ER_NEW_PWD_SENT').'. '.i18n_r('LOGIN').'
'.i18n_r('ERROR').': '.i18n_r('ER_SENDMAIL_ERR').'.
'.i18n_r('ER_FILE_DEL_SUC').': '.$errid.'
'.i18n_r('FLUSHCACHE-SUCCESS').'
'.i18n_r('ERROR').': '.i18n_r('ER_PROBLEM_DEL').'.
'.i18n_r('ER_COMPONENT_SAVE').'. '.i18n_r('UNDO').'
'.i18n_r('ER_COMPONENT_REST').'. '.i18n_r('UNDO').'
'.i18n_r('ERROR').': '. $error .'
'.i18n_r('ER_OLD_RESTORED').'. '.i18n_r('UNDO').'
'.i18n_r('ER_OLD_RESTORED').'. '.i18n_r('UNDO').'
'.i18n_r('ER_CANCELLED_FAIL').'
'.$error.'
'.i18n_r('ERROR').': '.$err.'
'.$success.'
'.i18n_r('ER_OLD_RESTORED').'. '.i18n_r('UNDO').'
'; - foreach ($GS_debug as $log){ - if(is_array($log)) print_r($log).''; - echo '
'; - else print($log.'
'); - } - echo '