Adding a link with nid in Global: results summary in Views I have a Views block listing a certain amount of nodes, and I've added a header field: Global: Result summary.

I am on the page: http://myexample.com/node/145 for example and with the header field, I want to link to: http://myexample.com/node/145/events. I have put the following code in the field:

(@total)

But this omits the nid and goes directly to:
http://myexample.com/node/events.

Does anyone know how to pass a URL argument for that field? I would ideally want to use arg(1).
Because the header uses the default Drupal PHP interpreter, Views variables aren't available there like they are in the arg php code. You can get them by doing something like this:

&lt;?php
global $current_view;
print $current_view-&gt;args[0];
?&gt;


Update: If you want to use PHP in views header, you can go to configure header, select "Global: Text area" and have to change text format to PHP code; you have to first install the PHP filter module.

Also if you use Global: Text area with PHP filter enabled this should work:

&lt;a href="%/events"&gt;@total&lt;/a&gt;