WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm working on a IP Locator Service, and I want to display a Customized Google Map which shows the visitor's location. It works fine here, but I don't know how to incorporate it into my Blog.

I've got the "html/javascript in Wordpress" Plugin, but I also need to apply a few Meta tags to the page. Is there any plugin/tweak that allows to add a meta tag only to one page?

Please Help!!

Edit: I also need to include javascript (< script>< /script>). How can I do that?

share|improve this question
up vote 1 down vote accepted

You have two options. Both involve using a conditional tag. I don't know which conditional you'll need to test for, hence the "{something}" placeholder. (If I had to guess, you may use the is_page( $ID ) tag.)

Edit your theme header file.

It's usually called header.php:

if( is_{something}() ) {
    echo '<meta ......... />';

Use the wp_head hook in your functions.php file

function wpse_54694() {
    if( is_{something}() ) {
        echo '<meta ......... />';
add_action( 'wp_head', 'wpse_54694' );
share|improve this answer
Thanks! I'll give it a try – Nick Jun 9 '12 at 18:28

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.