a global function for url query
<p>I have written a function:</p>

<pre><code>function url_query(){
  if (is_numeric($_GET['cmd'])) {
    $get = $_GET['cmd'];
  }
  return $get;
}
</code></pre>

<p>but I want that this function be global. This function works only for eg.  </p>

<pre><code>index.php?cmd=...
</code></pre>

<p>Can I revise this function to use for index.php?page=... and index.php?catID=... etc?
Thanks </p>
