Skip to content

Instantly share code, notes, and snippets.

@beneverard
Created November 23, 2011 16:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save beneverard/1389103 to your computer and use it in GitHub Desktop.
Save beneverard/1389103 to your computer and use it in GitHub Desktop.
Exposing WP url using shortcode
<?php
// slap this in your functions file
function wp_url_func($atts, $content=null)
{
return get_bloginfo('wp_url');
}
add_shortcode('wp_url', 'wp_url_func');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment