$items[] = array(<br>
 &nbsp; &nbsp;&#39;path&#39; =&gt; &#39;admin/settings/featured-<div id=":mh" class="ArwC7c ckChnd">comments/feature&#39;,<br>
 &nbsp; &nbsp;&#39;title&#39; =&gt; t(&#39;featured comment&#39;),<br>
 &nbsp; &nbsp;&#39;callback&#39; =&gt; &#39;feature_comment&#39;,<br>
 &nbsp; &nbsp;&#39;callback_args&#39; =&gt; $_GET[&#39;cid&#39;],<br><br>should be..<br><br>$items[] = array(<br>
 &nbsp; &nbsp;&#39;path&#39; =&gt; &#39;admin/settings/featured-comments/feature/%&#39;,<br><div id=":mh" class="ArwC7c ckChnd">
 &nbsp; &nbsp;&#39;title&#39; =&gt; t(&#39;featured comment&#39;),<br>
 &nbsp; &nbsp;&#39;callback&#39; =&gt; &#39;feature_comment&#39;,<br>
 &nbsp; &nbsp;&#39;callback_args&#39; =&gt;array(4),</div>...<br><br>try this..<br></div><br><br><div class="gmail_quote">On Tue, Feb 3, 2009 at 12:46 PM, Steven Jones <span dir="ltr">&lt;<a href="mailto:darthsteven@gmail.com">darthsteven@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">I&#39;m not how to relates to development of Drupal, so I&#39;ll try to kill<br>
this thread, here&#39;s the main issue:<br>
<br>
Your hook_menu returns an item with a &#39;callback_args&#39;, key, that key<br>
should be: &#39;callback arguments&#39; and the value should be an array of<br>
arguments to pass to the callback.<br>
<br>
<a href="http://api.drupal.org/api/function/hook_menu/5" target="_blank">http://api.drupal.org/api/function/hook_menu/5</a><br>
<br>
Regards<br>
Steven Jones<br>
ComputerMinds ltd - Perfect Drupal Websites<br>
<br>
Phone : 0121 288 0434<br>
Mobile : 07951 270 026<br>
<a href="http://www.computerminds.co.uk" target="_blank">http://www.computerminds.co.uk</a><br>
<br>
<br>
<br>
2009/2/3 cooper Quintin &lt;<a href="mailto:cooperq@cooperq.com">cooperq@cooperq.com</a>&gt;:<br>
<div><div></div><div class="Wj3C7c">&gt; Hello all,<br>
&gt; I am writing a module and I am trying to use a url as a callback<br>
&gt; argument, but it does not work. &nbsp;Here is the code:<br>
&gt;<br>
&gt; $items[] = array(<br>
&gt; &nbsp; &nbsp;&#39;path&#39; =&gt; &#39;admin/settings/featured-comments/feature&#39;,<br>
&gt; &nbsp; &nbsp;&#39;title&#39; =&gt; t(&#39;featured comment&#39;),<br>
&gt; &nbsp; &nbsp;&#39;callback&#39; =&gt; &#39;feature_comment&#39;,<br>
&gt; &nbsp; &nbsp;&#39;callback_args&#39; =&gt; $_GET[&#39;cid&#39;],<br>
&gt; &nbsp; &nbsp;&#39;access&#39; =&gt; user_access(&#39;administer comments&#39;),<br>
&gt; &nbsp; &nbsp;&#39;type&#39; =&gt; MENU_CALLBACK<br>
&gt; &nbsp;);<br>
&gt;<br>
&gt; and the callback function:<br>
&gt; function feature_comment($cid) {<br>
&gt; &nbsp;$comment = _comment_load($cid);<br>
&gt; &nbsp;db_query(&quot;UPDATE {featured_comments} SET featured=1 WHERE cid=%d&quot;, $cid);<br>
&gt; &nbsp;drupal_goto(&quot;node/$comment-&gt;nid&quot;);<br>
&gt; }<br>
&gt;<br>
&gt; going to an example url:<br>
&gt; <a href="http://example.com/admin/settings/featured-comments/feature?cid=10840" target="_blank">http://example.com/admin/settings/featured-comments/feature?cid=10840</a><br>
&gt; gives the following error: warning: Missing argument 1 for<br>
&gt; feature_comment() in<br>
&gt; /var/www/html/sites/all/modules/featured_comments/featured_comments.module<br>
&gt; on line 149.<br>
&gt;<br>
&gt;<br>
&gt; So my question is, what is the best way to use parts of the linked url<br>
&gt; as a callback argument for a function, because obviously it is not what<br>
&gt; I am doing!<br>
&gt; Thanks,<br>
&gt;<br>
&gt; --<br>
&gt; Cooper Quintin<br>
&gt; Freelance Programmer, Indymedia Journalist<br>
&gt; <a href="http://CooperQ.com" target="_blank">http://CooperQ.com</a><br>
&gt; (510) 827-5382<br>
&gt;<br>
&gt;<br>
</div></div></blockquote></div><br>