bigdon
27th March 2009, 05:05 PM
Hello
Did the script ugcms when I go in the index.php <? Php include file = "in.php"?> Insert I just get a white page I have also tried the <? Php include file = "in.php"? > ind the index.html inserted into but will not be counted
what can I do to ensure that the counting
index.php I have added
<?php
// ----------------------------------------------------------------------------------------------------
// - INI
// ----------------------------------------------------------------------------------------------------
$_INI = @parse_ini_file('admin/config/config.ini', TRUE);
// ----------------------------------------------------------------------------------------------------
// - Include
// ----------------------------------------------------------------------------------------------------
include('php/index.inc.php');
// ----------------------------------------------------------------------------------------------------
// - Log
// ----------------------------------------------------------------------------------------------------
if(PAGE_LOG_ENABLED == TRUE)
{
WriteLog();
};
// ----------------------------------------------------------------------------------------------------
// - MicroTime
// ----------------------------------------------------------------------------------------------------
$microtime = GetMicroTime();
// ----------------------------------------------------------------------------------------------------
// - Session
// ----------------------------------------------------------------------------------------------------
if(isset($_COOKIE[@session_name()]) == TRUE)
{
@ini_set('url_rewriter.tags', '');
@ini_set('session.use_cookies', 1);
@ini_set('session.use_only_cookies', 1);
@session_set_cookie_params(0, PAGE_ROOT_FOLDER . '/');
@session_start();
};
// ----------------------------------------------------------------------------------------------------
// - USER NOBODY
// ----------------------------------------------------------------------------------------------------
if(@is_array($_SESSION) == FALSE)
{
$_SESSION = Array();
};
if(@is_array($_SESSION['user']) == FALSE)
{
$_SESSION['user'] = Array(
'id' => PAGE_USER_ID_NOBODY,
'group_id' => PAGE_USERGROUP_ID_NOBODY,
'permissions' => PAGE_USER_AREA_NOBODY_PERMISSIONS
);
};
// ----------------------------------------------------------------------------------------------------
// - SQL Connect
// ----------------------------------------------------------------------------------------------------
$conn = NULL;
if(PAGE_COLLECT_KEYWORDS == TRUE)
{
@include(PAGE_DOCUMENT_ROOT . '/php/modules/seo/main.collect.inc.php');
};
// ----------------------------------------------------------------------------------------------------
// - Referer Plugin
// ----------------------------------------------------------------------------------------------------
if(isset($_SERVER['HTTP_REFERER']) == TRUE) // ((isset($_GET['in']) == FALSE) && (isset($_SERVER['HTTP_REFERER']) == TRUE))
{
if(PAGE_PARTNER_REFERER_PLUGIN_PATH)
{
if(@file_exists(PAGE_DOCUMENT_ROOT . PAGE_PARTNER_REFERER_PLUGIN_PATH))
{
@include(PAGE_DOCUMENT_ROOT . PAGE_PARTNER_REFERER_PLUGIN_PATH);
};
};
};
// ----------------------------------------------------------------------------------------------------
// - IN / OUT Plugin
// ----------------------------------------------------------------------------------------------------
if(isset($_GET['in']) == TRUE)
{
if(PAGE_PARTNER_IN_PLUGIN_PATH)
{
if(@file_exists(PAGE_DOCUMENT_ROOT . PAGE_PARTNER_IN_PLUGIN_PATH))
{
@include(PAGE_DOCUMENT_ROOT . PAGE_PARTNER_IN_PLUGIN_PATH);
};
};
}
else if(isset($_GET['out']) == TRUE)
{
if(PAGE_PARTNER_OUT_PLUGIN_PATH)
{
if(@file_exists(PAGE_DOCUMENT_ROOT . PAGE_PARTNER_OUT_PLUGIN_PATH))
{
@include(PAGE_DOCUMENT_ROOT . PAGE_PARTNER_OUT_PLUGIN_PATH);
};
};
};
// ----------------------------------------------------------------------------------------------------
// - Cache
// ----------------------------------------------------------------------------------------------------
/* if(($_SERVER['REQUEST_METHOD'] == 'GET') && (isset($_GET['in']) == FALSE) && (isset($_GET['out']) == FALSE))
{
if(PAGE_CACHE_TIMEOUT_BROWSER > 0)
{
$time = @time();
$last_modified = (@floor($time / PAGE_CACHE_TIMEOUT_BROWSER) * PAGE_CACHE_TIMEOUT_BROWSER);
$expires = (@ceil($time / PAGE_CACHE_TIMEOUT_BROWSER) * PAGE_CACHE_TIMEOUT_BROWSER);
@header('Date: ' . @gmdate('D, d M Y H:i:s \G\M\T', $time));
@header('Last-Modified: ' . @gmdate('D, d M Y H:i:s \G\M\T', $last_modified));
@header('Expires: ' . @gmdate('D, d M Y H:i:s \G\M\T', $expires));
};
if(($_SERVER['HTTP_ACCEPT_ENCODING'] != '') && (PAGE_COMPRESSION_LEVEL >= 0) && (PAGE_COMPRESSION_LEVEL <= 9))
{
if(@preg_match('/gzip/', $_SERVER['HTTP_ACCEPT_ENCODING']))
{
if($output = Cache_Output_OpenFile(@md5($_SERVER['REQUEST_URI']), 'gzip'))
{
@header('Content-Encoding: gzip');
@header('Content-Length: ' . @strlen($output));
echo $output;
exit;
};
}
else if(@preg_match('/deflate/', $_SERVER['HTTP_ACCEPT_ENCODING']))
{
if($output = Cache_Output_OpenFile(@md5($_SERVER['REQUEST_URI']), 'deflate'))
{
@header('Content-Encoding: deflate');
@header('Content-Length: ' . @strlen($output));
echo $output;
exit;
};
}
else
{
if($output = Cache_Output_OpenFile(@md5($_SERVER['REQUEST_URI']), 'html'))
{
@header('Content-Length: ' . @strlen($output));
echo $output;
exit;
};
};
}
else
{
if($output = Cache_Output_OpenFile(@md5($_SERVER['REQUEST_URI']), 'html'))
{
@header('Content-Length: ' . @strlen($output));
echo $output;
exit;
};
};
}; */
// ----------------------------------------------------------------------------------------------------
// - Main
// ----------------------------------------------------------------------------------------------------
$_GET['start'] = @max(@intval($_GET['start']), 1);
if(isset($_GET['q']) == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/entries/search.main.inc.php');
}
else if(isset($_GET['err']) == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/error/error.main.inc.php');
}
else if(isset($_GET['enter']) == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/enter/enter.main.inc.php');
}
else if(isset($_GET['p']) == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/sites/sites.main.inc.php');
}
else if(isset($_GET['cat']) == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/entries/categories.main.inc.php');
}
else if(isset($_GET['id']) == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/entries/item.main.inc.php');
}
else
{
if(PAGE_USE_TOPFRAME == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/frame/frame.main.inc.php');
}
else
{
if(PAGE_USE_ENTERPAGE == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/enter/enter.main.inc.php');
}
else
{
@header('Location: ' . PAGE_ROOT_FOLDER . PAGE_START_URL);
};
};
};
?>
Did the script ugcms when I go in the index.php <? Php include file = "in.php"?> Insert I just get a white page I have also tried the <? Php include file = "in.php"? > ind the index.html inserted into but will not be counted
what can I do to ensure that the counting
index.php I have added
<?php
// ----------------------------------------------------------------------------------------------------
// - INI
// ----------------------------------------------------------------------------------------------------
$_INI = @parse_ini_file('admin/config/config.ini', TRUE);
// ----------------------------------------------------------------------------------------------------
// - Include
// ----------------------------------------------------------------------------------------------------
include('php/index.inc.php');
// ----------------------------------------------------------------------------------------------------
// - Log
// ----------------------------------------------------------------------------------------------------
if(PAGE_LOG_ENABLED == TRUE)
{
WriteLog();
};
// ----------------------------------------------------------------------------------------------------
// - MicroTime
// ----------------------------------------------------------------------------------------------------
$microtime = GetMicroTime();
// ----------------------------------------------------------------------------------------------------
// - Session
// ----------------------------------------------------------------------------------------------------
if(isset($_COOKIE[@session_name()]) == TRUE)
{
@ini_set('url_rewriter.tags', '');
@ini_set('session.use_cookies', 1);
@ini_set('session.use_only_cookies', 1);
@session_set_cookie_params(0, PAGE_ROOT_FOLDER . '/');
@session_start();
};
// ----------------------------------------------------------------------------------------------------
// - USER NOBODY
// ----------------------------------------------------------------------------------------------------
if(@is_array($_SESSION) == FALSE)
{
$_SESSION = Array();
};
if(@is_array($_SESSION['user']) == FALSE)
{
$_SESSION['user'] = Array(
'id' => PAGE_USER_ID_NOBODY,
'group_id' => PAGE_USERGROUP_ID_NOBODY,
'permissions' => PAGE_USER_AREA_NOBODY_PERMISSIONS
);
};
// ----------------------------------------------------------------------------------------------------
// - SQL Connect
// ----------------------------------------------------------------------------------------------------
$conn = NULL;
if(PAGE_COLLECT_KEYWORDS == TRUE)
{
@include(PAGE_DOCUMENT_ROOT . '/php/modules/seo/main.collect.inc.php');
};
// ----------------------------------------------------------------------------------------------------
// - Referer Plugin
// ----------------------------------------------------------------------------------------------------
if(isset($_SERVER['HTTP_REFERER']) == TRUE) // ((isset($_GET['in']) == FALSE) && (isset($_SERVER['HTTP_REFERER']) == TRUE))
{
if(PAGE_PARTNER_REFERER_PLUGIN_PATH)
{
if(@file_exists(PAGE_DOCUMENT_ROOT . PAGE_PARTNER_REFERER_PLUGIN_PATH))
{
@include(PAGE_DOCUMENT_ROOT . PAGE_PARTNER_REFERER_PLUGIN_PATH);
};
};
};
// ----------------------------------------------------------------------------------------------------
// - IN / OUT Plugin
// ----------------------------------------------------------------------------------------------------
if(isset($_GET['in']) == TRUE)
{
if(PAGE_PARTNER_IN_PLUGIN_PATH)
{
if(@file_exists(PAGE_DOCUMENT_ROOT . PAGE_PARTNER_IN_PLUGIN_PATH))
{
@include(PAGE_DOCUMENT_ROOT . PAGE_PARTNER_IN_PLUGIN_PATH);
};
};
}
else if(isset($_GET['out']) == TRUE)
{
if(PAGE_PARTNER_OUT_PLUGIN_PATH)
{
if(@file_exists(PAGE_DOCUMENT_ROOT . PAGE_PARTNER_OUT_PLUGIN_PATH))
{
@include(PAGE_DOCUMENT_ROOT . PAGE_PARTNER_OUT_PLUGIN_PATH);
};
};
};
// ----------------------------------------------------------------------------------------------------
// - Cache
// ----------------------------------------------------------------------------------------------------
/* if(($_SERVER['REQUEST_METHOD'] == 'GET') && (isset($_GET['in']) == FALSE) && (isset($_GET['out']) == FALSE))
{
if(PAGE_CACHE_TIMEOUT_BROWSER > 0)
{
$time = @time();
$last_modified = (@floor($time / PAGE_CACHE_TIMEOUT_BROWSER) * PAGE_CACHE_TIMEOUT_BROWSER);
$expires = (@ceil($time / PAGE_CACHE_TIMEOUT_BROWSER) * PAGE_CACHE_TIMEOUT_BROWSER);
@header('Date: ' . @gmdate('D, d M Y H:i:s \G\M\T', $time));
@header('Last-Modified: ' . @gmdate('D, d M Y H:i:s \G\M\T', $last_modified));
@header('Expires: ' . @gmdate('D, d M Y H:i:s \G\M\T', $expires));
};
if(($_SERVER['HTTP_ACCEPT_ENCODING'] != '') && (PAGE_COMPRESSION_LEVEL >= 0) && (PAGE_COMPRESSION_LEVEL <= 9))
{
if(@preg_match('/gzip/', $_SERVER['HTTP_ACCEPT_ENCODING']))
{
if($output = Cache_Output_OpenFile(@md5($_SERVER['REQUEST_URI']), 'gzip'))
{
@header('Content-Encoding: gzip');
@header('Content-Length: ' . @strlen($output));
echo $output;
exit;
};
}
else if(@preg_match('/deflate/', $_SERVER['HTTP_ACCEPT_ENCODING']))
{
if($output = Cache_Output_OpenFile(@md5($_SERVER['REQUEST_URI']), 'deflate'))
{
@header('Content-Encoding: deflate');
@header('Content-Length: ' . @strlen($output));
echo $output;
exit;
};
}
else
{
if($output = Cache_Output_OpenFile(@md5($_SERVER['REQUEST_URI']), 'html'))
{
@header('Content-Length: ' . @strlen($output));
echo $output;
exit;
};
};
}
else
{
if($output = Cache_Output_OpenFile(@md5($_SERVER['REQUEST_URI']), 'html'))
{
@header('Content-Length: ' . @strlen($output));
echo $output;
exit;
};
};
}; */
// ----------------------------------------------------------------------------------------------------
// - Main
// ----------------------------------------------------------------------------------------------------
$_GET['start'] = @max(@intval($_GET['start']), 1);
if(isset($_GET['q']) == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/entries/search.main.inc.php');
}
else if(isset($_GET['err']) == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/error/error.main.inc.php');
}
else if(isset($_GET['enter']) == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/enter/enter.main.inc.php');
}
else if(isset($_GET['p']) == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/sites/sites.main.inc.php');
}
else if(isset($_GET['cat']) == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/entries/categories.main.inc.php');
}
else if(isset($_GET['id']) == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/entries/item.main.inc.php');
}
else
{
if(PAGE_USE_TOPFRAME == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/frame/frame.main.inc.php');
}
else
{
if(PAGE_USE_ENTERPAGE == TRUE)
{
include(PAGE_DOCUMENT_ROOT . '/php/modules/enter/enter.main.inc.php');
}
else
{
@header('Location: ' . PAGE_ROOT_FOLDER . PAGE_START_URL);
};
};
};
?>