
![]() ![]() |
| templates4all |
Message #1
|
| Active participant
Reputation: 0 ![]() Group: Administrator Posts: 114 ICQ:-- |
First we have to ask this question : What Is a Title Tag? In HTML and XHTML, a title tag is the tag that defines the title in three circumstances: in the bar at the top of the window above browser tabs and the toolbar; when the page is added to a user’s favorites (though the user can edit it there, and is more likely to do so if it is long); and when the page is displayed in search engine results. For these reasons, it is a good idea to: - create a title tag for each web page; - differentiate the title tags for each of your web pages; and - keep your title tag short and to the point. How Title Tags Are Constructed in General The title tag is part of the head of the page. Thus, it appears inside the head tag. In both HTML and XHTML, it is a toggle tag. This means it has an on and an off tag enclosing it. So, for example, if the title of your blog is “Burning Grapefruit,” the code would look like this: <html> <head> <title>Burning Grapefruit</title> </head> How Title Tags Are Constructed in WordPress The default for WordPress title tags is to display the blog name follwed by the » character followed by the post name. The blog’s name is pulled from bloginfo, and the PHP looks like this, where ‘name’ represents the post name: <title><?php bloginfo('name'); ?> <?php wp_title(); ?></title> If your post name was Grapefruit Flambé, then the PHP would look like this: <title><?php bloginfo('Grapefruit Flambé'); ?> <?php wp_title(); ?></title> and the title at the top of the browser window would look like this: Burning Grapefruit » Grapefruit Flambé It is possible to make a variety of changes to the appearance of the title, for example: turn off the » symbol substitute a pipe separator | for the » substitute a dash – for the » substitute a comma , for the » substitute a space for the » reverse the relative position of the blog and the post title, placing the post title first and the blog title second Double dashes and underscores are not recommended as separators. Other Approaches to Title Tags WordPress themes may provide different types of access to title tags. There are also a variety of title tag WordPress plug-ins. Using either of these its likely to provide added functionality so that the user can replace/override post titles in your title tags, since the parameters for post title and title tags are somewhat different and post titles may not make good title tags. If you consider adding a plug-in, make sure that it is compatible with the version of WordPress you are using, and if you are not using the latest version of WordPress, (3.2.1, as of July 2011), this is a good time to consider upgrading. Sources http://www.w3schools.com/tags/tag_title.asp http://codex.wordpress.org/Function_Reference/wp_title http://wordpress.org/extend/plugins/search.php?q=title+tag |
![]() ![]() |
1Pers. read this topic (guests: 1)
Users: 0
| Now: 22 May 2012 06:46 |
DLE Forum v.2.3 © 2012 Pocketx.Ru











