spacer

Webref WebRef   Sitemap · Experts · Tools · Services · Newsletters · About i.com

home / experts / dlab / html-pre / chapter 43
Biz Resources
Network Security Services
VoIP
CRM Software
Developer News
MicrosoftÂ’s Automated Agent: Can We Talk?
Borland Finally Sells CodeGear
Red Hat Heads For The JON 2.0
 

HTML Unleashed PRE: Strategies for Indexing and Search Engines

 
 

The META tag

 
 

Getting back to HTML, you might wonder what the syntax is for adding keywords to a document.  Of course, the text of a page is the primary source of searchable material, but you may also need to add certain keywords without altering the page content.  (Changing text color to make keywords invisible in the body of a document is a really ugly trick; please never resort to it!)

The META tag serves this purpose (as well as several other purposes).  "Meta" is a Greek word for "over," and META tag was intended to carry all sorts of meta- information, that is, information about (or "over") information.  You should understand that using META for specifying keywords is not an HTML convention, but only one of the widely accepted uses of the tag.

A META tag usually takes the following form:

  <META name="..." content="...">

As you can see, the names of the META tag attributes are rather generic, which allows you to use the tag to express virtually any information that may be represented as a name-value pair.  For example, you could use META tags to supply information about yourself (name="author"), the program you used to create the HTML file (name="generator"), and so on.

Here's how the META tag is used for introducing your document to search engines:

 
 
 
  <META name="keywords"
     content="searching, search engines, keywords, HTML">
  <META name="description"
     content="A description of major web search engines, spiders,
              and search-friendly HTML authoring">
 
 
 

These tags should be placed within the HEAD element.  Keywords and phrases in the content of the tag with name="keywords" attribute can be separated by commas for better readability, although spiders usually ignore the separators.  The maximum number of keywords depends on the search engine in question; for some of them, 25 words or 200 characters have been quoted as the upper limit.

Hopefully, the keywords thus specified will be added to the searchable representation of the document in the engine's database, and the description will be stored as the summary to be displayed for the document in a list of results (in the absence of a description, most search engines will take the first lines of text on the page).

Another use of the META tag is for excluding a page from spiders' attention.  By adding the following tag,

  <META name="robots" content="noindex">

you instruct any spiders that run into your page to bypass it without indexing.

However, not all spiders support this convention.  A more reliable solution is to add a robots.txt file to the root directory of your web server, with a list of files that must be excluded from indexing.  For example, your robots.txt might contain these lines:

  User-agent: *
  Disallow: /dont_index_me.html
  Disallow: /hidden_dir/

With these lines, no robot will scan the dont_index_me.html document, nor any document from the /hidden_dir/.  For more information on robots exclusion, refer to http://info.webcrawler.com/mak/projects/robots/exclusion.html.

 

Produced by Dmitry Kirsanov
Copyright Sams.net Publishing and


JupiterOnlineMedia

internet.comearthweb.comDevx.commediabistro.comGraphics.com

Search:

Jupitermedia Corporation has two divisions: Jupiterimages and JupiterOnlineMedia

Jupitermedia Corporate Info


Legal Notices, Licensing, Reprints, & Permissions, Privacy Policy.

Advertise | Newsletters | Tech Jobs | Shopping | E-mail Offers

Solutions
Whitepapers and eBooks
Microsoft Article: HyperV-The Killer Feature in WinServer ‘08
Avaya Article: How to Feed Data into the Avaya Event Processor
Microsoft Article: Install What You Need with Win Server ‘08
HP eBook: Putting the Green into IT
Whitepaper: HP Integrated Citrix XenServer for HP ProLiant Servers
Intel Go Parallel Portal: Interview with C++ Guru Herb Sutter, Part 1
Intel Go Parallel Portal: Interview with C++ Guru Herb Sutter, Part 2--The Future of Concurrency
Avaya Article: Setting Up a SIP A/S Development Environment
IBM Article: How Cool Is Your Data Center?
Microsoft Article: Managing Virtual Machines with Microsoft System Center
HP eBook: Storage Networking , Part 1
Microsoft Article: Solving Data Center Complexity with Microsoft System Center Configuration Manager 2007
MORE WHITEPAPERS, EBOOKS, AND ARTICLES
Webcasts
Intel Video: Are Multi-core Processors Here to Stay?
On-Demand Webcast: Five Virtualization Trends to Watch
HP Video: Page Cost Calculator
Intel Video: APIs for Parallel Programming
HP Webcast: Storage Is Changing Fast - Be Ready or Be Left Behind
Microsoft Silverlight Video: Creating Fading Controls with Expression Design and Expression Blend 2
MORE WEBCASTS, PODCASTS, AND VIDEOS
Downloads and eKits
Sun Download: Solaris 8 Migration Assistant
Sybase Download: SQL Anywhere Developer Edition
Red Gate Download: SQL Backup Pro and free DBA Best Practices eBook
Red Gate Download: SQL Compare Pro 6
Iron Speed Designer Application Generator
MORE DOWNLOADS, EKITS, AND FREE TRIALS
Tutorials and Demos
How-to-Article: Preparing for Hyper-Threading Technology and Dual Core Technology
eTouch PDF: Conquering the Tyranny of E-Mail and Word Processors
IBM Article: Collaborating in the High-Performance Workplace
HP Demo: StorageWorks EVA4400
Intel Featured Algorhythm: Intel Threading Building Blocks--The Pipeline Class
Microsoft How-to Article: Get Going with Silverlight and Windows Live
MORE TUTORIALS, DEMOS AND STEP-BY-STEP GUIDES
webref The latest from WebReference.com Browse >
Software Engineering for Ajax · Perl Pragma Primer · Implement Drag and Drop in Your Web Apps: Part 2
Sitemap · Experts · Tools · Services · Email a Colleague · Contact FREE Newsletters 
 The latest from internet.com
Wi-FiPlanet Gift Guide, Class of 2008 · Patriot Updates their DDR2 4GB PC2-8500 Line to "Revision 2" · Review: Samsung SCX-4500 Multifunction Printer

Created: Sept. 19, 1997
Revised: Sept. 19, 1997

URL: http://www.webreference.com/dlab/books/html-pre/43-2-2.html