Location: PHPKode > projects > Pindorama > pindorama/etc/includes/search-vars.php
<?php
global $sc;
if ($sc['method'] == "") { $sc['method'] = "and"; if ($_GET["method"] == "or") { $sc['method'] = "or"; } }
if (!is_array($sc['restrict'])) { $sc['restrict'] = $_GET["restrict"]; }
if (!is_array($sc['exclude'])) { $sc['exclude'] = $_GET["exclude"]; }
if ($sc['sort'] == "") { if ($_GET["sort"] != "" && $_GET["sort"] != "score") { $sc['sort'] = clean_arg($_GET["sort"], FALSE); } }
if ($sc["meta"] == "") { $sc["meta"] = $_GET["meta"]; }
if ($sc["maximun"] == "" || $sc["maximun"] <= 0) { $sc["maximun"] = 20; }
$sc["words"] = $_GET["words"]; if (is_array($sc["words"])) { $sc["words"] = implode(" ", $sc["words"]); } $sc["words"] = stripslashes($sc["words"]);
$sc["dates"]  = $_GET["date"];
$sc["begin"] = (int)$_GET["begin"]; if (!is_int($sc["begin"]) || $sc["begin"] <= 0) { $sc["begin"] = 1; }
$sc["hits-per-page"] = 20;
if ($sc["indexfile"] == "") { $sc["indexfile"] = $sc["index_dir"]."index.swish-e"; }
$sc["keys"] = "swishreccount swishrank swishdocpath swishtitle swishdocsize swishlastmodified swishdescription title date subject description extent publisher identifier format language source creator";
$sc["sys"] = $_ENV["OS"]; if (preg_match("/win/i", $sc["sys"])) { $sc["sep"] = "\""; $sc["win"] = FALSE; } else { $sc["sep"] = ""; $sc["win"] = TRUE; }
$sc["aliases"] = array( "swishtitle"=>"title", "swishlastmodified"=>"date", "swishdescription"=>"subject", "swishdocsize"=>"extent");
if ($sc["host"] == "") { $sc["host"] = $_SERVER["HTTP_HOST"]; }
if ($sc["template"] == "") { $sc["template"] = <<<EOF
<p class="title"><a href="[[swishdocpath]]">[[title]]</a></p>
<p class="subject">[[subject]]</p>
<p class="info"><span>URL: </span> http://{$sc["host"]}[[swishdocpath]] <span>Data: </span>[[date]] <span>Tamanho: </span> [[extent]] bytes</p>
EOF;
}
?>
Return current item: Pindorama