<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:arial, helvetica, sans-serif;font-size:12pt"><DIV></DIV>
<DIV>Also, arg(0), arg(1), arg(2), ... are available to the block. These are the real path components, not the URL alias stuff.<BR>&nbsp;</DIV>
<P><FONT face="bookman old style, new york, times, serif" color=#ff007f size=4><EM><STRONG>Nancy E. Wichmann, PMP</STRONG></EM></FONT></P>
<P><FONT face="arial, helvetica, sans-serif">Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.</FONT></P>
<DIV><BR></DIV>
<DIV style="FONT-SIZE: 12pt; FONT-FAMILY: arial, helvetica, sans-serif"><BR>
<DIV style="FONT-SIZE: 10pt; FONT-FAMILY: arial, helvetica, sans-serif"><FONT face=Tahoma size=2>
<HR SIZE=1>
<B><SPAN style="FONT-WEIGHT: bold">From:</SPAN></B> Daniel F. Kudwien &lt;news@unleashedmind.com&gt;<BR><B><SPAN style="FONT-WEIGHT: bold">To:</SPAN></B> development@drupal.org<BR><B><SPAN style="FONT-WEIGHT: bold">Sent:</SPAN></B> Fri, April 23, 2010 12:03:17 PM<BR><B><SPAN style="FONT-WEIGHT: bold">Subject:</SPAN></B> Re: [development] Blocks and page context<BR></FONT><BR>$_GET['q'] holds the current, internal system path.<BR><BR>menu_get_item() provides you the currently active menu router item.<BR><BR>menu_get_object() provides you a dynamic argument context from the menu<BR>router item, if any.<BR>http://api.drupal.org/api/function/menu_get_object/6<BR><BR>sun<BR><BR>________________________________<BR><BR>&nbsp;&nbsp;&nbsp; From: <A href="mailto:development-bounces@drupal.org" ymailto="mailto:development-bounces@drupal.org">development-bounces@drupal.org</A><BR>[mailto:<A href="mailto:development-bounces@drupal.org"
 ymailto="mailto:development-bounces@drupal.org">development-bounces@drupal.org</A>] On Behalf Of E.J. Zufelt<BR>&nbsp;&nbsp;&nbsp; Sent: Friday, April 23, 2010 4:49 PM<BR>&nbsp;&nbsp;&nbsp; To: <A href="mailto:development@drupal.org" ymailto="mailto:development@drupal.org">development@drupal.org</A><BR>&nbsp;&nbsp;&nbsp; Subject: [development] Blocks and page context<BR>&nbsp;&nbsp;&nbsp; <BR>&nbsp;&nbsp;&nbsp; <BR>&nbsp;&nbsp;&nbsp; Good morning, <BR><BR>&nbsp;&nbsp;&nbsp; I am building a module and invoking hook_block.&nbsp; I am wondering if<BR>there is a way for my block to gain some context about the page on which it<BR>will be rendered.&nbsp; Primarily I would like to know if my block can be aware<BR>of the URL of the page being displayed (not the http-requested URL in case<BR>they differ), and the access permissions of the page being displayed (not<BR>those of the block itself, or of the user accessing the block.<BR><BR>&nbsp;&nbsp;&nbsp;
 Thanks,<BR>&nbsp;&nbsp;&nbsp; <BR><BR><BR>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; Everett Zufelt<BR>&nbsp;&nbsp;&nbsp; <BR>&nbsp;&nbsp;&nbsp; http://zufelt.ca<BR><BR>&nbsp;&nbsp;&nbsp; Follow me on Twitter<BR>&nbsp;&nbsp;&nbsp; http://twitter.com/ezufelt<BR>&nbsp;&nbsp;&nbsp; <BR>&nbsp;&nbsp;&nbsp; View my LinkedIn Profile<BR>&nbsp;&nbsp;&nbsp; http://www.linkedin.com/in/ezufelt<BR><BR>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <BR>&nbsp;&nbsp;&nbsp; <BR><BR><BR><BR></DIV></DIV></div></body></html>