Viewing 1 replies (of 1 total)
  • I don’t know of a specific WordPress tag for that, but php can do it:

    <?php
    echo $_SERVER['PHP_SELF'];
    ?>

    From the php documentation on php_self: The filename of the currently executing script, relative to the document root. For instance, $_SERVER[‘PHP_SELF’] in a script at the address http://example.com/test.php/foo.bar would be /test.php/foo.bar.

Viewing 1 replies (of 1 total)

The topic ‘Code/tag for getting current URL?’ is closed to new replies.