mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-03 14:10:57 +08:00
fix imdb in new structure
This commit is contained in:
@@ -209,6 +209,9 @@ $responseBody = $response->getBody();
|
|||||||
}
|
}
|
||||||
if( $this->page[$wt] ){ //storecache
|
if( $this->page[$wt] ){ //storecache
|
||||||
if ($this->storecache) {
|
if ($this->storecache) {
|
||||||
|
if (!is_dir($this->cachedir)) {
|
||||||
|
$mkdirResult = mkdir($this->cachedir, 0777, true);
|
||||||
|
}
|
||||||
$fp = fopen ("$this->cachedir/$this->imdbID.$wt", "w");
|
$fp = fopen ("$this->cachedir/$this->imdbID.$wt", "w");
|
||||||
fputs ($fp, $this->page[$wt]);
|
fputs ($fp, $this->page[$wt]);
|
||||||
fclose ($fp);
|
fclose ($fp);
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ class imdb_config {
|
|||||||
$this->imdbsite = "www.imdb.com";
|
$this->imdbsite = "www.imdb.com";
|
||||||
// cachedir should be writable by the webserver. This doesn't need to be
|
// cachedir should be writable by the webserver. This doesn't need to be
|
||||||
// under documentroot.
|
// under documentroot.
|
||||||
$this->cachedir = './imdb/cache';
|
$this->cachedir = ROOT_PATH . 'imdb/cache';
|
||||||
//whether to use a cached page to retrieve the information if available.
|
//whether to use a cached page to retrieve the information if available.
|
||||||
$this->usecache = true;
|
$this->usecache = true;
|
||||||
//whether to store the pages retrieved for later use.
|
//whether to store the pages retrieved for later use.
|
||||||
@@ -58,10 +58,10 @@ class imdb_config {
|
|||||||
$this->imageext = '.jpg';
|
$this->imageext = '.jpg';
|
||||||
// images are stored here after calling photo_localurl()
|
// images are stored here after calling photo_localurl()
|
||||||
// this needs to be under documentroot to be able to display them on your pages.
|
// this needs to be under documentroot to be able to display them on your pages.
|
||||||
$this->photodir = './imdb/images/';
|
$this->photodir = ROOT_PATH . 'imdb/pic_imdb/';
|
||||||
// this is the URL to the images, i.e. start at your servers DOCUMENT_ROOT
|
// this is the URL to the images, i.e. start at your servers DOCUMENT_ROOT
|
||||||
// when specifying absolute path
|
// when specifying absolute path
|
||||||
$this->photoroot = './imdb/images/';
|
$this->photoroot = '/pic_imdb/';
|
||||||
// TWEAKING OPTIONS:
|
// TWEAKING OPTIONS:
|
||||||
// limit the result set to X movies (0 to disable, comment out to use default of 20)
|
// limit the result set to X movies (0 to disable, comment out to use default of 20)
|
||||||
$this->maxresults = 5000;
|
$this->maxresults = 5000;
|
||||||
|
|||||||
@@ -3,7 +3,6 @@ define('NEXUS_START', microtime(true));
|
|||||||
# IMPORTANT: Do not edit below unless you know what you are doing!
|
# IMPORTANT: Do not edit below unless you know what you are doing!
|
||||||
define('IN_TRACKER', true);
|
define('IN_TRACKER', true);
|
||||||
$rootpath= dirname(__DIR__) . '/';
|
$rootpath= dirname(__DIR__) . '/';
|
||||||
|
|
||||||
require $rootpath . 'include/functions_announce.php';
|
require $rootpath . 'include/functions_announce.php';
|
||||||
require $rootpath . 'include/globalfunctions.php';
|
require $rootpath . 'include/globalfunctions.php';
|
||||||
require $rootpath . 'include/core.php';
|
require $rootpath . 'include/core.php';
|
||||||
|
|||||||
@@ -69,9 +69,7 @@ if (basename($_SERVER['SCRIPT_FILENAME']) == 'announce.php') {
|
|||||||
}
|
}
|
||||||
$settings = get_setting();
|
$settings = get_setting();
|
||||||
foreach ($settings as $name => $value) {
|
foreach ($settings as $name => $value) {
|
||||||
$prefix = strtoupper(strstr($name, '.', true));
|
$GLOBALS[strtoupper($name)] = $value;
|
||||||
$pureName = substr($name, strpos($name, '.') + 1);
|
|
||||||
$GLOBALS[$prefix][$pureName] = $value;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
$SITENAME = $BASIC['SITENAME'];
|
$SITENAME = $BASIC['SITENAME'];
|
||||||
|
|||||||
@@ -1,7 +1,14 @@
|
|||||||
<?php
|
<?php
|
||||||
if(!defined('IN_TRACKER'))
|
if(!defined('IN_TRACKER')) {
|
||||||
die('Hacking attempt!');
|
die('Hacking attempt!');
|
||||||
|
}
|
||||||
error_reporting(E_ALL);
|
error_reporting(E_ALL);
|
||||||
|
if (!empty($_SERVER['HTTP_X_REQUEST_ID'])) {
|
||||||
|
define('REQUEST_ID', $_SERVER['HTTP_X_REQUEST_ID']);
|
||||||
|
} else {
|
||||||
|
define('REQUEST_ID', intval(NEXUS_START * 10000));
|
||||||
|
}
|
||||||
|
define('ROOT_PATH', $rootpath);
|
||||||
|
|
||||||
require $rootpath . 'include/database/interface_db.php';
|
require $rootpath . 'include/database/interface_db.php';
|
||||||
require $rootpath . 'include/database/class_db_mysqli.php';
|
require $rootpath . 'include/database/class_db_mysqli.php';
|
||||||
|
|||||||
@@ -1339,6 +1339,7 @@ function check_email ($email) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function sent_mail($to,$fromname,$fromemail,$subject,$body,$type = "confirmation",$showmsg=true,$multiple=false,$multiplemail='',$hdr_encoding = 'UTF-8', $specialcase = '') {
|
function sent_mail($to,$fromname,$fromemail,$subject,$body,$type = "confirmation",$showmsg=true,$multiple=false,$multiplemail='',$hdr_encoding = 'UTF-8', $specialcase = '') {
|
||||||
|
do_log("to: $to, fromname: $fromname, fromemail: $fromemail, subject: $subject, body: $body. type: $type");
|
||||||
global $lang_functions;
|
global $lang_functions;
|
||||||
global $rootpath,$SITENAME,$SITEEMAIL,$smtptype,$smtp,$smtp_host,$smtp_port,$smtp_from,$smtpaddress,$smtpport,$accountname,$accountpassword;
|
global $rootpath,$SITENAME,$SITEEMAIL,$smtptype,$smtp,$smtp_host,$smtp_port,$smtp_from,$smtpaddress,$smtpport,$accountname,$accountpassword;
|
||||||
# Is the OS Windows or Mac or Linux?
|
# Is the OS Windows or Mac or Linux?
|
||||||
@@ -1423,24 +1424,31 @@ function sent_mail($to,$fromname,$fromemail,$subject,$body,$type = "confirmation
|
|||||||
|
|
||||||
$setting = get_setting('smtp');
|
$setting = get_setting('smtp');
|
||||||
// Create the Transport
|
// Create the Transport
|
||||||
$transport = (new Swift_SmtpTransport('smtp.example.org', 25))
|
$transport = (new Swift_SmtpTransport($setting['smtpaddress'], $setting['smtpport']))
|
||||||
->setUsername('your username')
|
->setUsername($setting['accountname'])
|
||||||
->setPassword('your password')
|
->setPassword($setting['accountpassword'])
|
||||||
;
|
;
|
||||||
|
|
||||||
// Create the Mailer using your created Transport
|
// Create the Mailer using your created Transport
|
||||||
$mailer = new Swift_Mailer($transport);
|
$mailer = new Swift_Mailer($transport);
|
||||||
|
|
||||||
// Create a message
|
// Create a message
|
||||||
$message = (new Swift_Message('Wonderful Subject'))
|
$message = (new Swift_Message($subject))
|
||||||
->setFrom(['john@doe.com' => 'John Doe'])
|
->setFrom($fromemail, $fromname)
|
||||||
->setTo(['receiver@domain.org', 'other@domain.org' => 'A name'])
|
->setTo([$to])
|
||||||
->setBody('Here is the message itself')
|
->setBody($body)
|
||||||
;
|
;
|
||||||
|
|
||||||
// Send the message
|
// Send the message
|
||||||
$result = $mailer->send($message);
|
try {
|
||||||
|
$result = $mailer->send($message);
|
||||||
|
if ($result == 0) {
|
||||||
|
stderr($lang_functions['std_error'], $lang_functions['text_unable_to_send_mail']);
|
||||||
|
}
|
||||||
|
} catch (\Exception $e) {
|
||||||
|
do_log("send email fail: " . $e->getMessage() . ", trace: " . $e->getTraceAsString());
|
||||||
|
stderr($lang_functions['std_error'], $lang_functions['text_unable_to_send_mail']);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
if ($showmsg) {
|
if ($showmsg) {
|
||||||
|
|||||||
@@ -147,14 +147,16 @@ function dd($vars)
|
|||||||
exit(0);
|
exit(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
function do_log($log)
|
function do_log($log, $level = 'info')
|
||||||
{
|
{
|
||||||
global $TWEAK;
|
global $TWEAK;
|
||||||
if (!empty($TWEAK['logging'])) {
|
if (!empty($TWEAK['logging'])) {
|
||||||
$backtrace = debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS, 2);
|
$backtrace = debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS, 2);
|
||||||
$content = sprintf(
|
$content = sprintf(
|
||||||
"[%s] %s:%s %s%s%s %s%s",
|
"[%s] [%s] [%s] %s:%s %s%s%s %s%s",
|
||||||
date('Y-m-d H:i:s'),
|
date('Y-m-d H:i:s'),
|
||||||
|
$level,
|
||||||
|
REQUEST_ID,
|
||||||
$backtrace[0]['file'] ?? '',
|
$backtrace[0]['file'] ?? '',
|
||||||
$backtrace[0]['line'] ?? '',
|
$backtrace[0]['line'] ?? '',
|
||||||
$backtrace[1]['class'] ?? '',
|
$backtrace[1]['class'] ?? '',
|
||||||
@@ -206,11 +208,10 @@ function __($name = null, $prefix = null)
|
|||||||
|
|
||||||
function config($key, $default = null)
|
function config($key, $default = null)
|
||||||
{
|
{
|
||||||
global $rootpath;
|
|
||||||
static $configs;
|
static $configs;
|
||||||
if (is_null($configs)) {
|
if (is_null($configs)) {
|
||||||
//get all configuration from config file
|
//get all configuration from config file
|
||||||
$files = glob($rootpath . 'config/*.php');
|
$files = glob(ROOT_PATH . 'config/*.php');
|
||||||
foreach ($files as $file) {
|
foreach ($files as $file) {
|
||||||
$basename = basename($file);
|
$basename = basename($file);
|
||||||
if ($basename == 'allconfig.php') {
|
if ($basename == 'allconfig.php') {
|
||||||
@@ -233,7 +234,7 @@ function config($key, $default = null)
|
|||||||
* @param null $name
|
* @param null $name
|
||||||
* @return array|mixed|string
|
* @return array|mixed|string
|
||||||
*/
|
*/
|
||||||
function get_setting($name = null, $prefix = null)
|
function get_setting($name = null)
|
||||||
{
|
{
|
||||||
static $settings;
|
static $settings;
|
||||||
if (is_null($settings)) {
|
if (is_null($settings)) {
|
||||||
@@ -246,36 +247,20 @@ function get_setting($name = null, $prefix = null)
|
|||||||
if (is_array($arr)) {
|
if (is_array($arr)) {
|
||||||
$value = $arr;
|
$value = $arr;
|
||||||
}
|
}
|
||||||
$settings[$row['name']] = $value;
|
arr_set($settings, $row['name'], $value);
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
if (!is_null($name)) {
|
|
||||||
if (!is_null($prefix)) {
|
|
||||||
$name = "$prefix.$name";
|
|
||||||
}
|
|
||||||
return $settings[$name] ?? null;
|
|
||||||
}
|
|
||||||
if (is_null($prefix)) {
|
|
||||||
return $settings;
|
|
||||||
}
|
|
||||||
$filtered = [];
|
|
||||||
foreach ($settings as $name => $value) {
|
|
||||||
if (preg_match("/^$prefix/", $name)) {
|
|
||||||
$nameWithoutPrefix = substr($name, strpos($name, '.') + 1);
|
|
||||||
$filtered[$nameWithoutPrefix] = $value;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return $filtered;
|
if (is_null($name)) {
|
||||||
|
return $settings;
|
||||||
|
}
|
||||||
|
return arr_get($settings, $name);
|
||||||
}
|
}
|
||||||
|
|
||||||
function env($key, $default = null)
|
function env($key, $default = null)
|
||||||
{
|
{
|
||||||
global $rootpath;
|
|
||||||
static $env;
|
static $env;
|
||||||
if (is_null($env)) {
|
if (is_null($env)) {
|
||||||
$envFile = $rootpath . '.env';
|
$envFile = ROOT_PATH . '.env';
|
||||||
if (!file_exists($envFile)) {
|
if (!file_exists($envFile)) {
|
||||||
throw new \RuntimeException(".env file is not exists in the root path.");
|
throw new \RuntimeException(".env file is not exists in the root path.");
|
||||||
}
|
}
|
||||||
@@ -325,6 +310,18 @@ function normalize_env($value)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get an item from an array using "dot" notation.
|
||||||
|
*
|
||||||
|
* referance to Laravel
|
||||||
|
*
|
||||||
|
* @author xiaomlove<1939737565@qq.com>
|
||||||
|
* @date 2021/1/14
|
||||||
|
* @param $array
|
||||||
|
* @param $key
|
||||||
|
* @param null $default
|
||||||
|
* @return mixed|null
|
||||||
|
*/
|
||||||
function arr_get($array, $key, $default = null)
|
function arr_get($array, $key, $default = null)
|
||||||
{
|
{
|
||||||
if (strpos($key, '.') === false) {
|
if (strpos($key, '.') === false) {
|
||||||
@@ -340,23 +337,44 @@ function arr_get($array, $key, $default = null)
|
|||||||
return $array;
|
return $array;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* From Laravel
|
||||||
|
*
|
||||||
|
* Set an array item to a given value using "dot" notation.
|
||||||
|
*
|
||||||
|
* If no key is given to the method, the entire array will be replaced.
|
||||||
|
*
|
||||||
|
* @param array $array
|
||||||
|
* @param string|null $key
|
||||||
|
* @param mixed $value
|
||||||
|
* @return array
|
||||||
|
*/
|
||||||
function arr_set(&$array, $key, $value)
|
function arr_set(&$array, $key, $value)
|
||||||
{
|
{
|
||||||
$parts = explode('.', $key);
|
if (is_null($key)) {
|
||||||
$last = null;
|
return $array = $value;
|
||||||
while (true) {
|
|
||||||
$segment = array_pop($parts);
|
|
||||||
if (empty($segment)) {
|
|
||||||
return $array;
|
|
||||||
}
|
|
||||||
if (is_null($last)) {
|
|
||||||
$array[$segment] = $value;
|
|
||||||
} else {
|
|
||||||
$array[$segment] = $array;
|
|
||||||
unset($array[$last]);
|
|
||||||
}
|
|
||||||
$last = $segment;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$keys = explode('.', $key);
|
||||||
|
|
||||||
|
foreach ($keys as $i => $key) {
|
||||||
|
if (count($keys) === 1) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
unset($keys[$i]);
|
||||||
|
|
||||||
|
// If the key doesn't exist at this depth, we will just create an empty array
|
||||||
|
// to hold the next value, allowing us to create the arrays to hold final
|
||||||
|
// values at the correct depth. Then we'll keep digging into the array.
|
||||||
|
if (! isset($array[$key]) || ! is_array($array[$key])) {
|
||||||
|
$array[$key] = [];
|
||||||
|
}
|
||||||
|
|
||||||
|
$array = &$array[$key];
|
||||||
|
}
|
||||||
|
|
||||||
|
$array[array_shift($keys)] = $value;
|
||||||
|
|
||||||
return $array;
|
return $array;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -300,13 +300,18 @@ if ($CURUSER && $showpolls_main == "yes")
|
|||||||
$os = array();
|
$os = array();
|
||||||
|
|
||||||
// Count votes
|
// Count votes
|
||||||
while (($arr2 = mysql_fetch_row($res) !== null) && isset($arr2[0]) && isset($vs[$arr2[0]]))
|
while ($arr2 = mysql_fetch_row($res)) {
|
||||||
$vs[$arr2[0]] ++;
|
if (!isset($vs[$arr2[0]])) {
|
||||||
|
$vs[$arr2[0]] = 0;
|
||||||
|
}
|
||||||
|
$vs[$arr2[0]] ++;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
reset($o);
|
reset($o);
|
||||||
for ($i = 0; $i < count($o); ++$i){
|
for ($i = 0; $i < count($o); ++$i){
|
||||||
if (isset($vs[$i]) && isset($o[$i]) && $o[$i])
|
if ($o[$i])
|
||||||
$os[$i] = array($vs[$i], $o[$i], $i);
|
$os[$i] = array($vs[$i] ?? 0, $o[$i], $i);//field 1: options vote count, field 2: option name, field 3: option index
|
||||||
}
|
}
|
||||||
|
|
||||||
function srt($a,$b)
|
function srt($a,$b)
|
||||||
|
|||||||
@@ -222,8 +222,8 @@ else {
|
|||||||
break;
|
break;
|
||||||
case "funbox":
|
case "funbox":
|
||||||
stdhead($lang_log['head_funbox']);
|
stdhead($lang_log['head_funbox']);
|
||||||
$query = mysql_real_escape_string(trim($_GET["query"]));
|
$query = mysql_real_escape_string(trim($_GET["query"] ?? ''));
|
||||||
$search = $_GET["search"];
|
$search = $_GET["search"] ?? '';
|
||||||
if($query){
|
if($query){
|
||||||
switch ($search){
|
switch ($search){
|
||||||
case "title": $wherea=" WHERE title LIKE '%$query%' AND status != 'banned'"; break;
|
case "title": $wherea=" WHERE title LIKE '%$query%' AND status != 'banned'"; break;
|
||||||
@@ -237,7 +237,7 @@ else {
|
|||||||
$addparam = "";
|
$addparam = "";
|
||||||
}
|
}
|
||||||
logmenu("funbox");
|
logmenu("funbox");
|
||||||
$opt = array (title => $lang_log['text_title'], body => $lang_log['text_body'], both => $lang_log['text_both']);
|
$opt = array ('title' => $lang_log['text_title'], 'body' => $lang_log['text_body'], 'both' => $lang_log['text_both']);
|
||||||
searchtable($lang_log['text_search_funbox'], 'funbox', $opt);
|
searchtable($lang_log['text_search_funbox'], 'funbox', $opt);
|
||||||
$res = sql_query("SELECT COUNT(*) FROM fun ".$wherea);
|
$res = sql_query("SELECT COUNT(*) FROM fun ".$wherea);
|
||||||
$row = mysql_fetch_array($res);
|
$row = mysql_fetch_array($res);
|
||||||
@@ -324,7 +324,7 @@ else {
|
|||||||
|
|
||||||
int_check($pollid,true);
|
int_check($pollid,true);
|
||||||
|
|
||||||
$sure = $_GET["sure"];
|
$sure = $_GET["sure"] ?? '';
|
||||||
if (!$sure)
|
if (!$sure)
|
||||||
stderr($lang_log['std_delete_poll'],$lang_log['std_delete_poll_confirmation'] .
|
stderr($lang_log['std_delete_poll'],$lang_log['std_delete_poll_confirmation'] .
|
||||||
"<a href=?action=poll&do=delete&pollid=$pollid&returnto=$returnto&sure=1>".$lang_log['std_here_if_sure'],false);
|
"<a href=?action=poll&do=delete&pollid=$pollid&returnto=$returnto&sure=1>".$lang_log['std_here_if_sure'],false);
|
||||||
@@ -394,13 +394,20 @@ else {
|
|||||||
$os = array(); // votes and options: array(array(123, "Option 1"), array(45, "Option 2"))
|
$os = array(); // votes and options: array(array(123, "Option 1"), array(45, "Option 2"))
|
||||||
|
|
||||||
// Count votes
|
// Count votes
|
||||||
while ($pollanswer = mysql_fetch_row($pollanswers))
|
while ($pollanswer = mysql_fetch_row($pollanswers)) {
|
||||||
$vs[$pollanswer[0]] += 1;
|
if (isset($pollanswer[0])) {
|
||||||
|
if (!isset($vs[$pollanswer[0]])) {
|
||||||
|
$vs[$pollanswer[0]] = 0;
|
||||||
|
}
|
||||||
|
$vs[$pollanswer[0]] += 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
reset($o);
|
reset($o);
|
||||||
for ($i = 0; $i < count($o); ++$i)
|
for ($i = 0; $i < count($o); ++$i)
|
||||||
if (isset($o[$i]) && isset($vs[$i]))
|
if ($o[$i])
|
||||||
$os[$i] = array($vs[$i], $o[$i]);
|
$os[$i] = array($vs[$i] ?? 0, $o[$i]);
|
||||||
|
|
||||||
print("<table width=100% class=main border=0 cellspacing=0 cellpadding=0>\n");
|
print("<table width=100% class=main border=0 cellspacing=0 cellpadding=0>\n");
|
||||||
$i = 0;
|
$i = 0;
|
||||||
|
|||||||
@@ -19,7 +19,8 @@ if ($action == "sendmail")
|
|||||||
{$lang_mailtest['mail_test_mail_content']}
|
{$lang_mailtest['mail_test_mail_content']}
|
||||||
EOD;
|
EOD;
|
||||||
|
|
||||||
sent_mail($email, $SITENAME, $SITEEMAIL, change_email_encode(get_langfolder_cookie(), $title), change_email_encode(get_langfolder_cookie(),$body), '', false, false, '', get_email_encode(get_langfolder_cookie()));
|
// sent_mail($email, $SITENAME, $SITEEMAIL, change_email_encode(get_langfolder_cookie(), $title), change_email_encode(get_langfolder_cookie(),$body), '', false, false, '', get_email_encode(get_langfolder_cookie()));
|
||||||
|
sent_mail($email, $SITENAME, $SITEEMAIL, $title, $body, '', false, false, '', get_email_encode(get_langfolder_cookie()));
|
||||||
|
|
||||||
stderr($lang_mailtest['std_success'], $lang_mailtest['std_success_note']);
|
stderr($lang_mailtest['std_success'], $lang_mailtest['std_success_note']);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -247,7 +247,7 @@ elseif ($action == 'savesettings_advertisement') // save advertisement
|
|||||||
}
|
}
|
||||||
elseif ($action == 'tweaksettings') // tweak settings
|
elseif ($action == 'tweaksettings') // tweak settings
|
||||||
{
|
{
|
||||||
$TWEAK = get_setting(null, 'tweak');
|
$TWEAK = get_setting('tweak');
|
||||||
stdhead($lang_settings['head_tweak_settings']);
|
stdhead($lang_settings['head_tweak_settings']);
|
||||||
print ($notice);
|
print ($notice);
|
||||||
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_tweak' />");
|
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_tweak' />");
|
||||||
@@ -272,7 +272,7 @@ elseif ($action == 'tweaksettings') // tweak settings
|
|||||||
}
|
}
|
||||||
elseif ($action == 'smtpsettings') // stmp settings
|
elseif ($action == 'smtpsettings') // stmp settings
|
||||||
{
|
{
|
||||||
$SMTP = get_setting(null, 'smtp');
|
$SMTP = get_setting('smtp');
|
||||||
stdhead($lang_settings['head_smtp_settings']);
|
stdhead($lang_settings['head_smtp_settings']);
|
||||||
print ($notice);
|
print ($notice);
|
||||||
print("<tbody>");
|
print("<tbody>");
|
||||||
@@ -302,7 +302,7 @@ print("</tbody>");
|
|||||||
}
|
}
|
||||||
elseif ($action == 'securitysettings') //security settings
|
elseif ($action == 'securitysettings') //security settings
|
||||||
{
|
{
|
||||||
$SECURITY = get_setting(null, 'security');
|
$SECURITY = get_setting('security');
|
||||||
stdhead($lang_settings['head_security_settings']);
|
stdhead($lang_settings['head_security_settings']);
|
||||||
print ($notice);
|
print ($notice);
|
||||||
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_security'>");
|
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_security'>");
|
||||||
@@ -320,7 +320,7 @@ elseif ($action == 'securitysettings') //security settings
|
|||||||
}
|
}
|
||||||
elseif ($action == 'authoritysettings') //Authority settings
|
elseif ($action == 'authoritysettings') //Authority settings
|
||||||
{
|
{
|
||||||
$AUTHORITY = get_setting(null, 'authority');
|
$AUTHORITY = get_setting('authority');
|
||||||
stdhead($lang_settings['head_authority_settings']);
|
stdhead($lang_settings['head_authority_settings']);
|
||||||
print ($notice);
|
print ($notice);
|
||||||
$maxclass = UC_SYSOP;
|
$maxclass = UC_SYSOP;
|
||||||
@@ -379,7 +379,7 @@ elseif ($action == 'basicsettings') // basic settings
|
|||||||
{
|
{
|
||||||
stdhead($lang_settings['head_basic_settings']);
|
stdhead($lang_settings['head_basic_settings']);
|
||||||
print ($notice);
|
print ($notice);
|
||||||
$config = get_setting(null, 'basic');
|
$config = get_setting('basic');
|
||||||
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_basic'>");
|
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_basic'>");
|
||||||
tr($lang_settings['row_site_name'],"<input type='text' style=\"width: 300px\" name=SITENAME value='".($config["SITENAME"] ? $config["SITENAME"]: "Nexus")."'> ".$lang_settings['text_site_name_note'], 1);
|
tr($lang_settings['row_site_name'],"<input type='text' style=\"width: 300px\" name=SITENAME value='".($config["SITENAME"] ? $config["SITENAME"]: "Nexus")."'> ".$lang_settings['text_site_name_note'], 1);
|
||||||
tr($lang_settings['row_base_url'],"<input type='text' style=\"width: 300px\" name=BASEURL value='".($config["BASEURL"] ? $config["BASEURL"] : $_SERVER["HTTP_HOST"])."'> ".$lang_settings['text_it_should_be'] . $_SERVER["HTTP_HOST"] . $lang_settings['text_base_url_note'], 1);
|
tr($lang_settings['row_base_url'],"<input type='text' style=\"width: 300px\" name=BASEURL value='".($config["BASEURL"] ? $config["BASEURL"] : $_SERVER["HTTP_HOST"])."'> ".$lang_settings['text_it_should_be'] . $_SERVER["HTTP_HOST"] . $lang_settings['text_base_url_note'], 1);
|
||||||
@@ -398,7 +398,7 @@ elseif ($action == 'basicsettings') // basic settings
|
|||||||
}
|
}
|
||||||
elseif ($action == 'attachmentsettings') // basic settings
|
elseif ($action == 'attachmentsettings') // basic settings
|
||||||
{
|
{
|
||||||
$ATTACHMENT = get_setting(null, 'attachment');
|
$ATTACHMENT = get_setting('attachment');
|
||||||
stdhead($lang_settings['head_attachment_settings']);
|
stdhead($lang_settings['head_attachment_settings']);
|
||||||
print ($notice);
|
print ($notice);
|
||||||
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_attachment'>");
|
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_attachment'>");
|
||||||
@@ -420,7 +420,7 @@ elseif ($action == 'attachmentsettings') // basic settings
|
|||||||
}
|
}
|
||||||
elseif ($action == 'advertisementsettings')
|
elseif ($action == 'advertisementsettings')
|
||||||
{
|
{
|
||||||
$ADVERTISEMENT = get_setting(null, 'advertisement');
|
$ADVERTISEMENT = get_setting('advertisement');
|
||||||
stdhead($lang_settings['head_advertisement_settings']);
|
stdhead($lang_settings['head_advertisement_settings']);
|
||||||
print ($notice);
|
print ($notice);
|
||||||
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_advertisement'>");
|
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_advertisement'>");
|
||||||
@@ -434,7 +434,7 @@ elseif ($action == 'advertisementsettings')
|
|||||||
}
|
}
|
||||||
elseif ($action == 'codesettings') // code settings
|
elseif ($action == 'codesettings') // code settings
|
||||||
{
|
{
|
||||||
$CODE = get_setting(null, 'code');
|
$CODE = get_setting('code');
|
||||||
stdhead($lang_settings['head_code_settings']);
|
stdhead($lang_settings['head_code_settings']);
|
||||||
print ($notice);
|
print ($notice);
|
||||||
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_code'>");
|
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_code'>");
|
||||||
@@ -446,7 +446,7 @@ elseif ($action == 'codesettings') // code settings
|
|||||||
print ("</form>");
|
print ("</form>");
|
||||||
}
|
}
|
||||||
elseif ($action == 'bonussettings'){
|
elseif ($action == 'bonussettings'){
|
||||||
$BONUS = get_setting(null, 'bonus');
|
$BONUS = get_setting('bonus');
|
||||||
stdhead($lang_settings['head_bonus_settings']);
|
stdhead($lang_settings['head_bonus_settings']);
|
||||||
print ($notice);
|
print ($notice);
|
||||||
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_bonus'>");
|
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_bonus'>");
|
||||||
@@ -480,7 +480,7 @@ elseif ($action == 'bonussettings'){
|
|||||||
print ("</form>");
|
print ("</form>");
|
||||||
}
|
}
|
||||||
elseif ($action == 'accountsettings'){
|
elseif ($action == 'accountsettings'){
|
||||||
$ACCOUNT = get_setting(null, 'account');
|
$ACCOUNT = get_setting('account');
|
||||||
stdhead($lang_settings['head_account_settings']);
|
stdhead($lang_settings['head_account_settings']);
|
||||||
print ($notice);
|
print ($notice);
|
||||||
$maxclass = UC_VIP;
|
$maxclass = UC_VIP;
|
||||||
@@ -524,7 +524,7 @@ elseif ($action == 'accountsettings'){
|
|||||||
}
|
}
|
||||||
elseif ($action == 'torrentsettings')
|
elseif ($action == 'torrentsettings')
|
||||||
{
|
{
|
||||||
$TORRENT = get_setting(null, 'torrent');
|
$TORRENT = get_setting('torrent');
|
||||||
stdhead($lang_settings['head_torrent_settings']);
|
stdhead($lang_settings['head_torrent_settings']);
|
||||||
print ($notice);
|
print ($notice);
|
||||||
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_torrent'>");
|
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_torrent'>");
|
||||||
@@ -556,7 +556,7 @@ elseif ($action == 'torrentsettings')
|
|||||||
}
|
}
|
||||||
elseif ($action == 'mainsettings') // main settings
|
elseif ($action == 'mainsettings') // main settings
|
||||||
{
|
{
|
||||||
$MAIN = get_setting(null, 'main');
|
$MAIN = get_setting('main');
|
||||||
stdhead($lang_settings['head_main_settings']);
|
stdhead($lang_settings['head_main_settings']);
|
||||||
print ($notice);
|
print ($notice);
|
||||||
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_main'>");
|
print ("<form method='post' action='".$_SERVER["SCRIPT_NAME"]."'><input type='hidden' name='action' value='savesettings_main'>");
|
||||||
|
|||||||
Reference in New Issue
Block a user