| |
-86400
// generalized version of cmd[]-c
// - fields and operators specifed
// - unlimited number of conditions
// - all default conditions from view definition are
// completely redefined by the specified ones
//optionaly set[] // setings to modify view behavior (can be combined with cmd)
// set[23]=listlen-20
// set[23]=mlx-EN-FR-DE
// - sets maximal number of viewed items in view 23 to 20
// - there can be more settings (future) - comma separated
//optionaly als[] // user alias - see slice.php3 for more details
// for more info see AA FAQ: http://apc-aa.sourceforge.net/faq/index.shtml#219
// handle with PHP magic quotes - quote the variables if quoting is set off
function Myaddslashes($val, $n=1) {
if (!is_array($val)) {
return addslashes($val);
}
for (reset($val); list($k, $v) = each($val); )
$ret[$k] = Myaddslashes($v, $n+1);
return $ret;
}
if (!get_magic_quotes_gpc()) {
// Overrides GPC variables
if ( isset($HTTP_GET_VARS) AND is_array($HTTP_GET_VARS))
for (reset($HTTP_GET_VARS); list($k, $v) = each($HTTP_GET_VARS); )
$$k = Myaddslashes($v);
if ( isset($HTTP_POST_VARS) AND is_array($HTTP_POST_VARS))
for (reset($HTTP_POST_VARS); list($k, $v) = each($HTTP_POST_VARS); )
$$k = Myaddslashes($v);
if ( isset($HTTP_COOKIE_VARS) AND is_array($HTTP_COOKIE_VARS))
for (reset($HTTP_COOKIE_VARS); list($k, $v) = each($HTTP_COOKIE_VARS); )
$$k = Myaddslashes($v);
}
require_once "./include/config.php3";
require_once AA_INC_PATH."easy_scroller.php3";
require_once AA_INC_PATH."util.php3";
require_once AA_INC_PATH."item.php3";
require_once AA_INC_PATH."view.php3";
require_once AA_INC_PATH."discussion.php3";
require_once AA_INC_PATH."pagecache.php3";
require_once AA_INC_PATH."searchlib.php3";
require_once AA_INC_PATH."locsessi.php3"; // DB_AA object definition
add_vars();
if (is_numeric($time_limit)) {
set_time_limit((int)$time_limit);
}
if (isset($slice_id)) $p_slice_id= q_pack_id($slice_id);
$db = new DB_AA; // open BD
$db2 = new DB_AA; // open BD
if ($time_limit) set_time_limit($time_limit);
if ($debug) huhl("Starting view");
// Need to be able to set content-type for RSS, cannot do it in the view
// because the cache wont reflect this
if ($contenttype) {
header("Content-type: $contenttype");
}
$text = GetView(ParseViewParameters());
if ($convertto AND $convertfrom) {
require_once AA_INC_PATH."convert_charset.class.php3";
$encoder = new ConvertCharset;
$text = $encoder->Convert($text, $convertfrom, $convertto);
}
echo $text;
if ($debug) huhl("Completed view");
exit;
?>
|
|
-86400
// generalized version of cmd[]-c
// - fields and operators specifed
// - unlimited number of conditions
// - all default conditions from view definition are
// completely redefined by the specified ones
//optionaly set[] // setings to modify view behavior (can be combined with cmd)
// set[23]=listlen-20
// set[23]=mlx-EN-FR-DE
// - sets maximal number of viewed items in view 23 to 20
// - there can be more settings (future) - comma separated
//optionaly als[] // user alias - see slice.php3 for more details
// for more info see AA FAQ: http://apc-aa.sourceforge.net/faq/index.shtml#219
// handle with PHP magic quotes - quote the variables if quoting is set off
function Myaddslashes($val, $n=1) {
if (!is_array($val)) {
return addslashes($val);
}
for (reset($val); list($k, $v) = each($val); )
$ret[$k] = Myaddslashes($v, $n+1);
return $ret;
}
if (!get_magic_quotes_gpc()) {
// Overrides GPC variables
if ( isset($HTTP_GET_VARS) AND is_array($HTTP_GET_VARS))
for (reset($HTTP_GET_VARS); list($k, $v) = each($HTTP_GET_VARS); )
$$k = Myaddslashes($v);
if ( isset($HTTP_POST_VARS) AND is_array($HTTP_POST_VARS))
for (reset($HTTP_POST_VARS); list($k, $v) = each($HTTP_POST_VARS); )
$$k = Myaddslashes($v);
if ( isset($HTTP_COOKIE_VARS) AND is_array($HTTP_COOKIE_VARS))
for (reset($HTTP_COOKIE_VARS); list($k, $v) = each($HTTP_COOKIE_VARS); )
$$k = Myaddslashes($v);
}
require_once "./include/config.php3";
require_once AA_INC_PATH."easy_scroller.php3";
require_once AA_INC_PATH."util.php3";
require_once AA_INC_PATH."item.php3";
require_once AA_INC_PATH."view.php3";
require_once AA_INC_PATH."discussion.php3";
require_once AA_INC_PATH."pagecache.php3";
require_once AA_INC_PATH."searchlib.php3";
require_once AA_INC_PATH."locsessi.php3"; // DB_AA object definition
add_vars();
if (is_numeric($time_limit)) {
set_time_limit((int)$time_limit);
}
if (isset($slice_id)) $p_slice_id= q_pack_id($slice_id);
$db = new DB_AA; // open BD
$db2 = new DB_AA; // open BD
if ($time_limit) set_time_limit($time_limit);
if ($debug) huhl("Starting view");
// Need to be able to set content-type for RSS, cannot do it in the view
// because the cache wont reflect this
if ($contenttype) {
header("Content-type: $contenttype");
}
$text = GetView(ParseViewParameters());
if ($convertto AND $convertfrom) {
require_once AA_INC_PATH."convert_charset.class.php3";
$encoder = new ConvertCharset;
$text = $encoder->Convert($text, $convertfrom, $convertto);
}
echo $text;
if ($debug) huhl("Completed view");
exit;
?>
|
|