Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #7767

    Hi guys,

    I would like to use a custom field on a page or maybe the page excerpt for a page to add custom text to each page’s browser title (<title>).

    I have found the header.php file and know that this is where I would be able to control this part, but don’t know what I would need to do on this piece of code to add this field.

    ‘<title><?php bloginfo(‘name’); ?> | <?php is_home() ? bloginfo(‘description’) : wp_title(”); ?></title>’

    This looks like it will add the blog name and if it is the home page, will also add the description, then the title of the page.

    I would also like it to display the excerpt of the page.

    Once I am able to do this, then this template will meet 100% of my requirements.

    thanks in advance.

    #59215

    Hey,

    I’d use plugins like: http://wordpress.org/extend/plugins/wordpress-seo/ because they allow you to set custom titles for each post/page (because of seo reasons, etc.).

Viewing 2 posts - 1 through 2 (of 2 total)

The topic ‘Custom fields in browser title bar’ is closed to new replies.