http://modx.ru/sites/?a[]=1 http://sweetmenu.ru/articles/news.html?a[]=1 http://rpkkub.ru/?a[]=1
<form action="http://modx.ru/assets/modules/docmanager/tv.ajax.php" method="POST"> <input type="text" name="tplID"> </form>
$dm->ph['ajax.endpoint'] = MODX_SITE_URL.'assets/modules/docmanager/tv.ajax.php';
$dm->ph['ajax.endpoint'] = MODX_SITE_URL.'assets/modules/docmanager/tv.ajax.php?myparameter=avalue';
$my_parameter = $_SERVER['argv'][0];
$my_value = whatever_myparameter=avalue_was_above;
if ($my_parameter != $my_value) die('<b>INCLUDE_ORDERING_ERROR</b><br /><br />Please use the MODx Content Manager instead of accessing this file directly.');

function applyHsc($var){
$var = htmlspecialchars($var, ENT_QUOTES);
}
function buildURL($args,$id=false,$dittoIdentifier=false) {
global $modx, $dittoID;
$dittoID = ($dittoIdentifier !== false) ? $dittoIdentifier : $dittoID;
$query = array();
//mrhaw http://modxcms.com/forums/index.php/topic,16456.msg123881.html#msg123881
foreach ($_GET as $param=>$value) {
if ($param != 'id' && $param != 'q') {
$keyparam =htmlspecialchars($param, ENT_QUOTES);
$keyvalue = (is_array($value)) ? array_walk($value,"ditto::applyHsc") : htmlspecialchars($value, ENT_QUOTES);
$query[$keyparam] = $keyvalue;
}
}
# if ($param != 'id' && $param != 'q') {
# $query[htmlspecialchars($param, ENT_QUOTES)] = htmlspecialchars($value, ENT_QUOTES);
# }