<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Balaramesht&#039;s Blog</title>
	<atom:link href="http://balaramesht.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://balaramesht.wordpress.com</link>
	<description>Just another WordPress.com weblog</description>
	<lastBuildDate>Thu, 24 Dec 2009 07:34:03 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='balaramesht.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>Balaramesht&#039;s Blog</title>
		<link>http://balaramesht.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://balaramesht.wordpress.com/osd.xml" title="Balaramesht&#039;s Blog" />
	<atom:link rel='hub' href='http://balaramesht.wordpress.com/?pushpress=hub'/>
		<item>
		<title>CSS Image Sprites</title>
		<link>http://balaramesht.wordpress.com/2009/12/24/32/</link>
		<comments>http://balaramesht.wordpress.com/2009/12/24/32/#comments</comments>
		<pubDate>Thu, 24 Dec 2009 06:33:56 +0000</pubDate>
		<dc:creator>balaramesht</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[CSS Image Sprites]]></category>
		<category><![CDATA[CSS image sprites tutorial]]></category>
		<category><![CDATA[CSS Sprite Generator]]></category>
		<category><![CDATA[CSS sprites]]></category>
		<category><![CDATA[CSS Toys for Professional Web Developers]]></category>
		<category><![CDATA[future CSS Lesson]]></category>
		<category><![CDATA[how to create css image sprites]]></category>
		<category><![CDATA[Image Sprites]]></category>

		<guid isPermaLink="false">http://balaramesht.wordpress.com/?p=32</guid>
		<description><![CDATA[CSS Image Sprites: How to Create CSS Sprites for Blog Icons, Web Site Icon Summary: Learn how to use CSS sprites to improve performance for our busy website pages. CSS sprites save HTTP requests by using CSS positioning to selectively &#8230; <a href="http://balaramesht.wordpress.com/2009/12/24/32/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=balaramesht.wordpress.com&amp;blog=10211564&amp;post=32&amp;subd=balaramesht&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><strong>CSS Image Sprites: How to Create CSS Sprites for Blog Icons, Web Site Icon</strong></p>
<p><strong><span style="text-decoration:underline;">Summary</span></strong><span style="text-decoration:underline;">:</span></p>
<p>Learn how to use CSS sprites to improve performance for our busy website pages. CSS sprites save HTTP requests by using CSS positioning to selectively display composite background images. To maximize accessibility and usability, CSS sprites are best used for icons or decorative effects.  </p>
<p><strong><span style="text-decoration:underline;">What is Image Sprites?</span></strong></p>
<p>CSS sprites group multiple images into one composite image and display them using CSS background positioning. You can save a significant amount of HTTP requests by consolidating your images into one or more composite sprites and using CSS to selectively display parts of the sprite within your web page. Now that the major browsers have evolved enough to support CSS backgrounds and positioning, more sites are adopting this performance technique. In fact, some of the busiest sites on the Web use CSS sprites to save HTTP requests. In this article we&#8217;ll expand on our mini-CSS sprite example to show how to use CSS sprites to improve performance. </p>
<p><strong><span style="text-decoration:underline;">How to make CSS Sprite</span></strong></p>
<p>The idea behind CSS sprites is to consolidate multiple images into one sprite and then selectively display portions of this sprite with positioning. The steps are as follows:</p>
<ul>
<li>Combine multiple images together (usually icons or decorative images) into one image.</li>
<li>Evenly space these images, aligned into one or more lines</li>
<li>Set this sprite to the background image of an element (usually a list)</li>
<li>Position the sprite to display the appropriate image by shifting the X or Y position by a multiple of the spacing</li>
<li>Enjoy the increased speed and reduced HTTP requests</li>
</ul>
<p>  <a href="http://balaramesht.files.wordpress.com/2009/12/imgsprite1.jpg"><img class="alignleft size-medium wp-image-33" title="imgsprite1" src="http://balaramesht.files.wordpress.com/2009/12/imgsprite1.jpg?w=300&#038;h=198" alt="CSS sprite" width="300" height="198" /></a></p>
<p><a href="http://balaramesht.files.wordpress.com/2009/12/imgsprite21.jpg"><img title="imgsprite2" src="http://balaramesht.files.wordpress.com/2009/12/imgsprite21.jpg?w=12&#038;h=300" alt="" width="12" height="300" /></a></p>
<p>The above fig shows the best example for CSS sprites from aol.com. The narrow sprite image has been used to achieve the web page. <a href="http://balaramesht.files.wordpress.com/2009/12/imgsprite21.jpg"></a></p>
<p>These are the <strong>CSS classes</strong> used to display the sprite image in corresponding position. </p>
<p>            <em>.dirmod .pi_Comments         {padding-left: 2em;background: url(../../common/i/icons_19x14.gif) no-repeat 2px -747px}</em></p>
<p><em>            .prod_ser .pi_Comments          {padding-left: 2em;background: url(../../common/i/icons_19x14.gif) no-repeat 2px -747px}</em></p>
<p><em>            . dirmod .pi_Filed          {padding-left: 2em;background: url(../../common/i/icons_19x14.gif) no-repeat 2px -777px}</em></p>
<p><em>            .prod_ser .pi_Filed       {padding-left: 2em;background: url(../../common/i/icons_19x14.gif) no-repeat 2px -777px}</em></p>
<p><em>           .dirmod .pi_RSS           {padding-left: 2em;background: url(../../common/i/icons_19x14.gif) no-repeat 1px -806px}</em></p>
<p><strong><span style="text-decoration:underline;">Conclusion</span></strong></p>
<p>So far we have been learned how to use CSS sprites to improve performance for our busy website pages. CSS sprites save HTTP requests by using CSS positioning to selectively display composite background images. Another benefit of CSS sprites is that the combined image is often smaller in file size than the individual images, despite adding white space between images. The smaller size of sprites is due to the reduced overhead of multiple color tables and formatting information required by separate images. To maximize accessibility and usability, CSS sprites are best used for icons or decorative effects.<strong></strong></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/balaramesht.wordpress.com/32/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/balaramesht.wordpress.com/32/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/balaramesht.wordpress.com/32/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/balaramesht.wordpress.com/32/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/balaramesht.wordpress.com/32/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/balaramesht.wordpress.com/32/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/balaramesht.wordpress.com/32/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/balaramesht.wordpress.com/32/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/balaramesht.wordpress.com/32/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/balaramesht.wordpress.com/32/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/balaramesht.wordpress.com/32/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/balaramesht.wordpress.com/32/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/balaramesht.wordpress.com/32/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/balaramesht.wordpress.com/32/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=balaramesht.wordpress.com&amp;blog=10211564&amp;post=32&amp;subd=balaramesht&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://balaramesht.wordpress.com/2009/12/24/32/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c8b0670188b175256018b1a9afa46b1?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">balaramesht</media:title>
		</media:content>

		<media:content url="http://balaramesht.files.wordpress.com/2009/12/imgsprite1.jpg?w=300" medium="image">
			<media:title type="html">imgsprite1</media:title>
		</media:content>

		<media:content url="http://balaramesht.files.wordpress.com/2009/12/imgsprite21.jpg?w=12" medium="image">
			<media:title type="html">imgsprite2</media:title>
		</media:content>
	</item>
		<item>
		<title>DateTimeFormatInfo Class</title>
		<link>http://balaramesht.wordpress.com/2009/11/04/datetimeformatinfo-class/</link>
		<comments>http://balaramesht.wordpress.com/2009/11/04/datetimeformatinfo-class/#comments</comments>
		<pubDate>Wed, 04 Nov 2009 03:30:56 +0000</pubDate>
		<dc:creator>balaramesht</dc:creator>
				<category><![CDATA[C Sharp]]></category>
		<category><![CDATA[datetime format]]></category>
		<category><![CDATA[datetime format in asp.net datagrid]]></category>
		<category><![CDATA[DateTime values are formatted and displayed]]></category>
		<category><![CDATA[DateTimeFormatInfo Class]]></category>
		<category><![CDATA[formating datetime in asp.net]]></category>
		<category><![CDATA[System.Globalization.DateTimeFormatInfo]]></category>

		<guid isPermaLink="false">http://balaramesht.wordpress.com/?p=26</guid>
		<description><![CDATA[Defines how DateTime values are formatted and displayed, depending on the culture. For a list of all members of this type, see DateTimeFormatInfo Members. System.Object    System.Globalization.DateTimeFormatInfo [Visual Basic] &#60;Serializable&#62; NotInheritable Public Class DateTimeFormatInfo Implements ICloneable, IFormatProvider [C#] [Serializable] public sealed class &#8230; <a href="http://balaramesht.wordpress.com/2009/11/04/datetimeformatinfo-class/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=balaramesht.wordpress.com&amp;blog=10211564&amp;post=26&amp;subd=balaramesht&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Defines how <a id="ctl00_contentContainer_ctl01" href="http://msdn.microsoft.com/en-us/library/system.datetime(VS.71).aspx">DateTime</a> values are formatted and displayed, depending on the culture.</p>
<p>For a list of all members of this type, see <a id="ctl00_contentContainer_ctl02" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo_members(VS.71).aspx">DateTimeFormatInfo Members</a>.</p>
<p><a id="ctl00_contentContainer_ctl03" href="http://msdn.microsoft.com/en-us/library/system.object(VS.71).aspx">System.Object</a><br />
   <strong>System.Globalization.DateTimeFormatInfo</strong></p>
<pre>[Visual Basic]
&lt;Serializable&gt;
<strong>NotInheritable Public Class DateTimeFormatInfo</strong>
<strong>   Implements ICloneable, IFormatProvider</strong>
[C#]
[Serializable]
<strong>public sealed class DateTimeFormatInfo : ICloneable,</strong>
<strong>   IFormatProvider</strong>
[C++]
[Serializable]
<strong>public __gc __sealed class DateTimeFormatInfo : public ICloneable,</strong>
<strong>   IFormatProvider</strong>
[JScript]
<strong>public
   </strong>Serializable
<strong>class DateTimeFormatInfo implements ICloneable,</strong>
<strong>   IFormatProvider</strong></pre>
<h4>Thread Safety</h4>
<p>Any public static (<strong>Shared</strong> in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.</p>
<h4>Remarks</h4>
<p>This class contains information, such as date patterns, time patterns, and AM/PM designators.</p>
<p>To create a <strong>DateTimeFormatInfo</strong> for a specific culture, create a <a id="ctl00_contentContainer_ctl04" href="http://msdn.microsoft.com/en-us/library/system.globalization.cultureinfo(VS.71).aspx">CultureInfo</a> for that culture and retrieve the <a id="ctl00_contentContainer_ctl05" href="http://msdn.microsoft.com/en-us/library/system.globalization.cultureinfo.datetimeformat(VS.71).aspx">CultureInfo.DateTimeFormat</a> property. To create a <strong>DateTimeFormatInfo</strong> for the culture of the current thread, use the <a id="ctl00_contentContainer_ctl06" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.currentinfo(VS.71).aspx">CurrentInfo</a> property. To create a <strong>DateTimeFormatInfo</strong> for the invariant culture, use the <a id="ctl00_contentContainer_ctl07" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.invariantinfo(VS.71).aspx">InvariantInfo</a> property for a read-only version, or use the <strong>DateTimeFormatInfo</strong> constructor for a writable version. It is not possible to create a <strong>DateTimeFormatInfo</strong> for a neutral culture.</p>
<p>The user might choose to override some of the values associated with the current culture of Windows through Regional and Language Options (or Regional Options or Regional Settings) in Control Panel. For example, the user might choose to display the date in a different format or to use a currency other than the default for the culture. If the <a id="ctl00_contentContainer_ctl08" href="http://msdn.microsoft.com/en-us/library/system.globalization.cultureinfo.useuseroverride(VS.71).aspx">CultureInfo.UseUserOverride</a> property is set to <strong>true</strong>, the properties of the <strong>CultureInfo.DateTimeFormat</strong> instance, the <a id="ctl00_contentContainer_ctl09" href="http://msdn.microsoft.com/en-us/library/system.globalization.cultureinfo.numberformat(VS.71).aspx">CultureInfo.NumberFormat</a> instance, and the <a id="ctl00_contentContainer_ctl10" href="http://msdn.microsoft.com/en-us/library/system.globalization.cultureinfo.textinfo(VS.71).aspx">CultureInfo.TextInfo</a> instance are also retrieved from the user settings. If the user settings are incompatible with the culture associated with the <strong>CultureInfo</strong> (for example, if the selected calendar is not one of the <a id="ctl00_contentContainer_ctl11" href="http://msdn.microsoft.com/en-us/library/system.globalization.cultureinfo.optionalcalendars(VS.71).aspx">OptionalCalendars</a>), the results of the methods and the values of the properties are undefined.</p>
<p><a id="ctl00_contentContainer_ctl12" href="http://msdn.microsoft.com/en-us/library/system.datetime(VS.71).aspx">DateTime</a> values are formatted using standard or custom patterns stored in the properties of a <strong>DateTimeFormatInfo</strong>.</p>
<p>The standard patterns can be replaced with custom patterns by setting the associated properties of a writable <strong>DateTimeFormatInfo</strong>. To determine if a <strong>DateTimeFormatInfo</strong> is writable, use the <a id="ctl00_contentContainer_ctl13" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.isreadonly(VS.71).aspx">IsReadOnly</a> property.</p>
<p>The following table lists the standard format characters for each standard pattern and the associated <strong>DateTimeFormatInfo</strong> property that can be set to modify the standard pattern. The format characters are case-sensitive; for example, &#8216;g&#8217; and &#8216;G&#8217; represent slightly different patterns.</p>
<div>
<table>
<tbody>
<tr valign="top">
<th width="50%">Format Character</th>
<th width="50%">Associated Property/ Description</th>
</tr>
<tr valign="top">
<td width="50%">d</td>
<td width="50%"><a id="ctl00_contentContainer_ctl14" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.shortdatepattern(VS.71).aspx">ShortDatePattern</a></td>
</tr>
<tr valign="top">
<td width="50%">D</td>
<td width="50%"><a id="ctl00_contentContainer_ctl15" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.longdatepattern(VS.71).aspx">LongDatePattern</a></td>
</tr>
<tr valign="top">
<td width="50%">f</td>
<td width="50%">Full date and time (long date and short time)</td>
</tr>
<tr valign="top">
<td width="50%">F</td>
<td width="50%"><a id="ctl00_contentContainer_ctl16" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.fulldatetimepattern(VS.71).aspx">FullDateTimePattern</a> (long date and long time)</td>
</tr>
<tr valign="top">
<td width="50%">g</td>
<td width="50%">General (short date and short time)</td>
</tr>
<tr valign="top">
<td width="50%">G</td>
<td width="50%">General (short date and long time)</td>
</tr>
<tr valign="top">
<td width="50%">m, M</td>
<td width="50%"><a id="ctl00_contentContainer_ctl17" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.monthdaypattern(VS.71).aspx">MonthDayPattern</a></td>
</tr>
<tr valign="top">
<td width="50%">r, R</td>
<td width="50%"><a id="ctl00_contentContainer_ctl18" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.rfc1123pattern(VS.71).aspx">RFC1123Pattern</a></td>
</tr>
<tr valign="top">
<td width="50%">s</td>
<td width="50%"><a id="ctl00_contentContainer_ctl19" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.sortabledatetimepattern(VS.71).aspx">SortableDateTimePattern</a> (based on ISO 8601) using local time</td>
</tr>
<tr valign="top">
<td width="50%">t</td>
<td width="50%"><a id="ctl00_contentContainer_ctl20" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.shorttimepattern(VS.71).aspx">ShortTimePattern</a></td>
</tr>
<tr valign="top">
<td width="50%">T</td>
<td width="50%"><a id="ctl00_contentContainer_ctl21" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.longtimepattern(VS.71).aspx">LongTimePattern</a></td>
</tr>
<tr valign="top">
<td width="50%">u</td>
<td width="50%"><a id="ctl00_contentContainer_ctl22" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.universalsortabledatetimepattern(VS.71).aspx">UniversalSortableDateTimePattern</a> using the format for universal time display</td>
</tr>
<tr valign="top">
<td width="50%">U</td>
<td width="50%">Full date and time (long date and long time) using universal time</td>
</tr>
<tr valign="top">
<td width="50%">y, Y</td>
<td width="50%"><a id="ctl00_contentContainer_ctl23" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.yearmonthpattern(VS.71).aspx">YearMonthPattern</a></td>
</tr>
</tbody>
</table>
</div>
<p>The following table lists the patterns that can be combined to construct custom patterns. The patterns are case-sensitive; for example, &#8220;MM&#8221; is recognized, but &#8220;mm&#8221; is not. If the custom pattern contains white-space characters or characters enclosed in single quotation marks, the output string will also contain those characters. Characters not defined as part of a format pattern or as format characters are reproduced literally.</p>
<div>
<table>
<tbody>
<tr valign="top">
<th width="50%">Format Pattern</th>
<th width="50%">Description</th>
</tr>
<tr valign="top">
<td width="50%">d</td>
<td width="50%">The day of the month. Single-digit days will not have a leading zero.</td>
</tr>
<tr valign="top">
<td width="50%">dd</td>
<td width="50%">The day of the month. Single-digit days will have a leading zero.</td>
</tr>
<tr valign="top">
<td width="50%">ddd</td>
<td width="50%">The abbreviated name of the day of the week, as defined in <a id="ctl00_contentContainer_ctl24" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.abbreviateddaynames(VS.71).aspx">AbbreviatedDayNames</a>.</td>
</tr>
<tr valign="top">
<td width="50%">dddd</td>
<td width="50%">The full name of the day of the week, as defined in <a id="ctl00_contentContainer_ctl25" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.daynames(VS.71).aspx">DayNames</a>.</td>
</tr>
<tr valign="top">
<td width="50%">M</td>
<td width="50%">The numeric month. Single-digit months will not have a leading zero.</td>
</tr>
<tr valign="top">
<td width="50%">MM</td>
<td width="50%">The numeric month. Single-digit months will have a leading zero.</td>
</tr>
<tr valign="top">
<td width="50%">MMM</td>
<td width="50%">The abbreviated name of the month, as defined in <a id="ctl00_contentContainer_ctl26" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.abbreviatedmonthnames(VS.71).aspx">AbbreviatedMonthNames</a>.</td>
</tr>
<tr valign="top">
<td width="50%">MMMM</td>
<td width="50%">The full name of the month, as defined in <a id="ctl00_contentContainer_ctl27" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.monthnames(VS.71).aspx">MonthNames</a>.</td>
</tr>
<tr valign="top">
<td width="50%">y</td>
<td width="50%">The year without the century. If the year without the century is less than 10, the year is displayed with no leading zero.</td>
</tr>
<tr valign="top">
<td width="50%">yy</td>
<td width="50%">The year without the century. If the year without the century is less than 10, the year is displayed with a leading zero.</td>
</tr>
<tr valign="top">
<td width="50%">yyyy</td>
<td width="50%">The year in four digits, including the century.</td>
</tr>
<tr valign="top">
<td width="50%">gg</td>
<td width="50%">The period or era. This pattern is ignored if the date to be formatted does not have an associated period or era string.</td>
</tr>
<tr valign="top">
<td width="50%">h</td>
<td width="50%">The hour in a 12-hour clock. Single-digit hours will not have a leading zero.</td>
</tr>
<tr valign="top">
<td width="50%">hh</td>
<td width="50%">The hour in a 12-hour clock. Single-digit hours will have a leading zero.</td>
</tr>
<tr valign="top">
<td width="50%">H</td>
<td width="50%">The hour in a 24-hour clock. Single-digit hours will not have a leading zero.</td>
</tr>
<tr valign="top">
<td width="50%">HH</td>
<td width="50%">The hour in a 24-hour clock. Single-digit hours will have a leading zero.</td>
</tr>
<tr valign="top">
<td width="50%">m</td>
<td width="50%">The minute. Single-digit minutes will not have a leading zero.</td>
</tr>
<tr valign="top">
<td width="50%">mm</td>
<td width="50%">The minute. Single-digit minutes will have a leading zero.</td>
</tr>
<tr valign="top">
<td width="50%">s</td>
<td width="50%">The second. Single-digit seconds will not have a leading zero.</td>
</tr>
<tr valign="top">
<td width="50%">ss</td>
<td width="50%">The second. Single-digit seconds will have a leading zero.</td>
</tr>
<tr valign="top">
<td width="50%">f</td>
<td width="50%">The fraction of a second in single-digit precision. The remaining digits are truncated.</td>
</tr>
<tr valign="top">
<td width="50%">ff</td>
<td width="50%">The fraction of a second in double-digit precision. The remaining digits are truncated.</td>
</tr>
<tr valign="top">
<td width="50%">fff</td>
<td width="50%">The fraction of a second in three-digit precision. The remaining digits are truncated.</td>
</tr>
<tr valign="top">
<td width="50%">ffff</td>
<td width="50%">The fraction of a second in four-digit precision. The remaining digits are truncated.</td>
</tr>
<tr valign="top">
<td width="50%">fffff</td>
<td width="50%">The fraction of a second in five-digit precision. The remaining digits are truncated.</td>
</tr>
<tr valign="top">
<td width="50%">ffffff</td>
<td width="50%">The fraction of a second in six-digit precision. The remaining digits are truncated.</td>
</tr>
<tr valign="top">
<td width="50%">fffffff</td>
<td width="50%">The fraction of a second in seven-digit precision. The remaining digits are truncated.</td>
</tr>
<tr valign="top">
<td width="50%">t</td>
<td width="50%">The first character in the AM/PM designator defined in <a id="ctl00_contentContainer_ctl28" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.amdesignator(VS.71).aspx">AMDesignator</a> or <a id="ctl00_contentContainer_ctl29" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.pmdesignator(VS.71).aspx">PMDesignator</a>, if any.</td>
</tr>
<tr valign="top">
<td width="50%">tt</td>
<td width="50%">The AM/PM designator defined in <a id="ctl00_contentContainer_ctl30" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.amdesignator(VS.71).aspx">AMDesignator</a> or <a id="ctl00_contentContainer_ctl31" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.pmdesignator(VS.71).aspx">PMDesignator</a>, if any.</td>
</tr>
<tr valign="top">
<td width="50%">z</td>
<td width="50%">The time zone offset (&#8220;+&#8221; or &#8220;-&#8221; followed by the hour only). Single-digit hours will not have a leading zero. For example, Pacific Standard Time is &#8220;-8&#8243;.</td>
</tr>
<tr valign="top">
<td width="50%">zz</td>
<td width="50%">The time zone offset (&#8220;+&#8221; or &#8220;-&#8221; followed by the hour only). Single-digit hours will have a leading zero. For example, Pacific Standard Time is &#8220;-08&#8243;.</td>
</tr>
<tr valign="top">
<td width="50%">zzz</td>
<td width="50%">The full time zone offset (&#8220;+&#8221; or &#8220;-&#8221; followed by the hour and minutes). Single-digit hours and minutes will have leading zeros. For example, Pacific Standard Time is &#8220;-08:00&#8243;.</td>
</tr>
<tr valign="top">
<td width="50%">:</td>
<td width="50%">The default time separator defined in <a id="ctl00_contentContainer_ctl32" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.timeseparator(VS.71).aspx">TimeSeparator</a>.</td>
</tr>
<tr valign="top">
<td width="50%">/</td>
<td width="50%">The default date separator defined in <a id="ctl00_contentContainer_ctl33" href="http://msdn.microsoft.com/en-us/library/system.globalization.datetimeformatinfo.dateseparator(VS.71).aspx">DateSeparator</a>.</td>
</tr>
<tr valign="top">
<td width="50%">% <em>c</em></td>
<td width="50%">Where <em>c</em> is a format pattern if used alone. The &#8220;%&#8221; character can be omitted if the format pattern is combined with literal characters or other format patterns.</td>
</tr>
<tr valign="top">
<td width="50%">\ <em>c</em></td>
<td width="50%">Where <em>c</em> is any character. Displays the character literally. To display the backslash character, use &#8220;\\&#8221;.</td>
</tr>
</tbody>
</table>
</div>
<p>Only format patterns listed in the second table above can be used to create custom patterns; standard format characters listed in the first table cannot be used to create custom patterns. Custom patterns are at least two characters long; for example,</p>
<ul type="disc">
<li>DateTime.ToString( &#8220;d&#8221;) returns the DateTime value; &#8220;d&#8221; is the standard short date pattern.</li>
<li>DateTime.ToString( &#8220;%d&#8221;) returns the day of the month; &#8220;%d&#8221; is a custom pattern.</li>
<li>DateTime.ToString( &#8220;d &#8220;) returns the day of the month followed by a white-space character; &#8220;d &#8221; is a custom pattern.</li>
</ul>
<p>A <strong>DateTimeFormatInfo</strong> or a <a id="ctl00_contentContainer_ctl34" href="http://msdn.microsoft.com/en-us/library/system.globalization.numberformatinfo(VS.71).aspx">NumberFormatInfo</a> can be created only for the invariant culture or for specific cultures, not for neutral cultures. For more information about the invariant culture, specific cultures, and neutral cultures, see the <strong>CultureInfo</strong> class.</p>
<p>This class implements the <a id="ctl00_contentContainer_ctl35" href="http://msdn.microsoft.com/en-us/library/system.icloneable(VS.71).aspx">ICloneable</a> interface to enable duplication of <strong>DateTimeFormatInfo</strong> objects. It also implements <a id="ctl00_contentContainer_ctl36" href="http://msdn.microsoft.com/en-us/library/system.iformatprovider(VS.71).aspx">IFormatProvider</a> to supply formatting information to applications.</p>
<h4>Example</h4>
<p>[Visual Basic, C#, C++] The following code example prints out the different format patterns for the en-US culture using the format characters. It also displays the value of the properties associated with the format character.</p>
<pre>[Visual Basic]
Imports System
Imports System.Globalization
Imports Microsoft.VisualBasic

Public Class SamplesDTFI

   Public Shared Sub Main()

      ' Creates and initializes a DateTimeFormatInfo associated with the en-US culture.
      Dim myDTFI As DateTimeFormatInfo = New CultureInfo("en-US", False).DateTimeFormat

      ' Creates a DateTime with the Gregorian date January 3, 2002 (year=2002, month=1, day=3).
      ' The Gregorian calendar is the default calendar for the en-US culture.
      Dim myDT As New DateTime(2002, 1, 3)

      ' Displays the format pattern associated with each format character.
      Console.WriteLine("FORMAT  en-US EXAMPLE")
      Console.WriteLine("CHAR    VALUE OF ASSOCIATED PROPERTY, IF ANY")
      Console.WriteLine()
      Console.WriteLine("  d     {0}", myDT.ToString("d"))
      Console.WriteLine("        {0} {1}", myDTFI.ShortDatePattern, "(ShortDatePattern)")
      Console.WriteLine()
      Console.WriteLine("  D     {0}", myDT.ToString("D"))
      Console.WriteLine("        {0} {1}", myDTFI.LongDatePattern, "(LongDatePattern)")
      Console.WriteLine()
      Console.WriteLine("  f     {0}", myDT.ToString("f"))
      Console.WriteLine()
      Console.WriteLine("  F     {0}", myDT.ToString("F"))
      Console.WriteLine("        {0} {1}", myDTFI.FullDateTimePattern, "(FullDateTimePattern)")
      Console.WriteLine()
      Console.WriteLine("  g     {0}", myDT.ToString("g"))
      Console.WriteLine()
      Console.WriteLine("  G     {0}", myDT.ToString("G"))
      Console.WriteLine()
      Console.WriteLine("  m     {0}", myDT.ToString("m"))
      Console.WriteLine("        {0} {1}", myDTFI.MonthDayPattern, "(MonthDayPattern)")
      Console.WriteLine()
      Console.WriteLine("  M     {0}", myDT.ToString("M"))
      Console.WriteLine("        {0} {1}", myDTFI.MonthDayPattern, "(MonthDayPattern)")
      Console.WriteLine()
      Console.WriteLine("  r     {0}", myDT.ToString("r"))
      Console.WriteLine("        {0} {1}", myDTFI.RFC1123Pattern, "(RFC1123Pattern)")
      Console.WriteLine()
      Console.WriteLine("  R     {0}", myDT.ToString("R"))
      Console.WriteLine("        {0} {1}", myDTFI.RFC1123Pattern, "(RFC1123Pattern)")
      Console.WriteLine()
      Console.WriteLine("  s     {0}", myDT.ToString("s"))
      Console.WriteLine("        {0} {1}", myDTFI.SortableDateTimePattern, "(SortableDateTimePattern)")
      Console.WriteLine()
      Console.WriteLine("  t     {0}", myDT.ToString("t"))
      Console.WriteLine("        {0} {1}", myDTFI.ShortTimePattern, "(ShortTimePattern)")
      Console.WriteLine()
      Console.WriteLine("  T     {0}", myDT.ToString("T"))
      Console.WriteLine("        {0} {1}", myDTFI.LongTimePattern, "(LongTimePattern)")
      Console.WriteLine()
      Console.WriteLine("  u     {0}", myDT.ToString("u"))
      Console.WriteLine("        {0} {1}", myDTFI.UniversalSortableDateTimePattern, "(UniversalSortableDateTimePattern)")
      Console.WriteLine()
      Console.WriteLine("  U     {0}", myDT.ToString("U"))
      Console.WriteLine()
      Console.WriteLine("  y     {0}", myDT.ToString("y"))
      Console.WriteLine("        {0} {1}", myDTFI.YearMonthPattern, "(YearMonthPattern)")
      Console.WriteLine()
      Console.WriteLine("  Y     {0}", myDT.ToString("Y"))
      Console.WriteLine("        {0} {1}", myDTFI.YearMonthPattern, "(YearMonthPattern)")

   End Sub 'Main 

End Class 'SamplesDTFI

'This code produces the following output.
'
'FORMAT  en-US EXAMPLE
'CHAR    VALUE OF ASSOCIATED PROPERTY, IF ANY
'
'  d     1/3/2002
'        M/d/yyyy (ShortDatePattern)
'
'  D     Thursday, January 03, 2002
'        dddd, MMMM dd, yyyy (LongDatePattern)
'
'  f     Thursday, January 03, 2002 12:00 AM
'
'  F     Thursday, January 03, 2002 12:00:00 AM
'        dddd, MMMM dd, yyyy h:mm:ss tt (FullDateTimePattern)
'
'  g     1/3/2002 12:00 AM
'
'  G     1/3/2002 12:00:00 AM
'
'  m     January 03
'        MMMM dd (MonthDayPattern)
'
'  M     January 03
'        MMMM dd (MonthDayPattern)
'
'  r     Thu, 03 Jan 2002 00:00:00 GMT
'        ddd, dd MMM yyyy HH':'mm':'ss 'GMT' (RFC1123Pattern)
'
'  R     Thu, 03 Jan 2002 00:00:00 GMT
'        ddd, dd MMM yyyy HH':'mm':'ss 'GMT' (RFC1123Pattern)
'
'  s     2002-01-03T00:00:00
'        yyyy'-'MM'-'dd'T'HH':'mm':'ss (SortableDateTimePattern)
'
'  t     12:00 AM
'        h:mm tt (ShortTimePattern)
'
'  T     12:00:00 AM
'        h:mm:ss tt (LongTimePattern)
'
'  u     2002-01-03 00:00:00Z
'        yyyy'-'MM'-'dd HH':'mm':'ss'Z' (UniversalSortableDateTimePattern)
'
'  U     Thursday, January 03, 2002 8:00:00 AM
'
'  y     January, 2002
'        MMMM, yyyy (YearMonthPattern)
'
'  Y     January, 2002
'        MMMM, yyyy (YearMonthPattern)
'

[C#]
using System;
using System.Globalization;

public class SamplesDTFI  {

   public static void Main()  {

      // Creates and initializes a DateTimeFormatInfo associated with the en-US culture.
      DateTimeFormatInfo myDTFI = new CultureInfo( "en-US", false ).DateTimeFormat;

      // Creates a DateTime with the Gregorian date January 3, 2002 (year=2002, month=1, day=3).
      // The Gregorian calendar is the default calendar for the en-US culture.
      DateTime myDT = new DateTime( 2002, 1, 3 );

      // Displays the format pattern associated with each format character.
      Console.WriteLine( "FORMAT  en-US EXAMPLE" );
      Console.WriteLine( "CHAR    VALUE OF ASSOCIATED PROPERTY, IF ANY\n" );
      Console.WriteLine( "  d     {0}", myDT.ToString("d") );
      Console.WriteLine( "        {0} {1}\n", myDTFI.ShortDatePattern, "(ShortDatePattern)" );
      Console.WriteLine( "  D     {0}", myDT.ToString("D") );
      Console.WriteLine( "        {0} {1}\n", myDTFI.LongDatePattern, "(LongDatePattern)" );
      Console.WriteLine( "  f     {0}\n", myDT.ToString("f") );
      Console.WriteLine( "  F     {0}", myDT.ToString("F") );
      Console.WriteLine( "        {0} {1}\n", myDTFI.FullDateTimePattern, "(FullDateTimePattern)" );
      Console.WriteLine( "  g     {0}\n", myDT.ToString("g") );
      Console.WriteLine( "  G     {0}\n", myDT.ToString("G") );
      Console.WriteLine( "  m     {0}", myDT.ToString("m") );
      Console.WriteLine( "        {0} {1}\n", myDTFI.MonthDayPattern, "(MonthDayPattern)" );
      Console.WriteLine( "  M     {0}", myDT.ToString("M") );
      Console.WriteLine( "        {0} {1}\n", myDTFI.MonthDayPattern, "(MonthDayPattern)" );
      Console.WriteLine( "  r     {0}", myDT.ToString("r") );
      Console.WriteLine( "        {0} {1}\n", myDTFI.RFC1123Pattern, "(RFC1123Pattern)" );
      Console.WriteLine( "  R     {0}", myDT.ToString("R") );
      Console.WriteLine( "        {0} {1}\n", myDTFI.RFC1123Pattern, "(RFC1123Pattern)" );
      Console.WriteLine( "  s     {0}", myDT.ToString("s") );
      Console.WriteLine( "        {0} {1}\n", myDTFI.SortableDateTimePattern, "(SortableDateTimePattern)" );
      Console.WriteLine( "  t     {0}", myDT.ToString("t") );
      Console.WriteLine( "        {0} {1}\n", myDTFI.ShortTimePattern, "(ShortTimePattern)" );
      Console.WriteLine( "  T     {0}", myDT.ToString("T") );
      Console.WriteLine( "        {0} {1}\n", myDTFI.LongTimePattern, "(LongTimePattern)" );
      Console.WriteLine( "  u     {0}", myDT.ToString("u") );
      Console.WriteLine( "        {0} {1}\n", myDTFI.UniversalSortableDateTimePattern, "(UniversalSortableDateTimePattern)" );
      Console.WriteLine( "  U     {0}\n", myDT.ToString("U") );
      Console.WriteLine( "  y     {0}", myDT.ToString("y") );
      Console.WriteLine( "        {0} {1}\n", myDTFI.YearMonthPattern, "(YearMonthPattern)" );
      Console.WriteLine( "  Y     {0}", myDT.ToString("Y") );
      Console.WriteLine( "        {0} {1}\n", myDTFI.YearMonthPattern, "(YearMonthPattern)" );

   }

}

/*
This code produces the following output.

FORMAT  en-US EXAMPLE
CHAR    VALUE OF ASSOCIATED PROPERTY, IF ANY

  d     1/3/2002
        M/d/yyyy (ShortDatePattern)

  D     Thursday, January 03, 2002
        dddd, MMMM dd, yyyy (LongDatePattern)

  f     Thursday, January 03, 2002 12:00 AM

  F     Thursday, January 03, 2002 12:00:00 AM
        dddd, MMMM dd, yyyy h:mm:ss tt (FullDateTimePattern)

  g     1/3/2002 12:00 AM

  G     1/3/2002 12:00:00 AM

  m     January 03
        MMMM dd (MonthDayPattern)

  M     January 03
        MMMM dd (MonthDayPattern)

  r     Thu, 03 Jan 2002 00:00:00 GMT
        ddd, dd MMM yyyy HH':'mm':'ss 'GMT' (RFC1123Pattern)

  R     Thu, 03 Jan 2002 00:00:00 GMT
        ddd, dd MMM yyyy HH':'mm':'ss 'GMT' (RFC1123Pattern)

  s     2002-01-03T00:00:00
        yyyy'-'MM'-'dd'T'HH':'mm':'ss (SortableDateTimePattern)

  t     12:00 AM
        h:mm tt (ShortTimePattern)

  T     12:00:00 AM
        h:mm:ss tt (LongTimePattern)

  u     2002-01-03 00:00:00Z
        yyyy'-'MM'-'dd HH':'mm':'ss'Z' (UniversalSortableDateTimePattern)

  U     Thursday, January 03, 2002 8:00:00 AM

  y     January, 2002
        MMMM, yyyy (YearMonthPattern)

  Y     January, 2002
        MMMM, yyyy (YearMonthPattern)

*/

[C++]
#using &lt;mscorlib.dll&gt;
using namespace System;
using namespace System::Globalization;

int main()
{
   // Creates and initializes a DateTimeFormatInfo associated with the en-US culture.
   CultureInfo * MyCI = new CultureInfo(S"en-US", false);
   DateTimeFormatInfo* myDTFI = MyCI -&gt; DateTimeFormat;

   // Creates a DateTime with the Gregorian date January 3, 2002 (year=2002, month=1, day=3).
   // The Gregorian calendar is the default calendar for the en-US culture.
   DateTime myDT = DateTime(2002, 1, 3);

   // Displays the format pattern associated with each format character.
   Console::WriteLine(S"FORMAT  en-US EXAMPLE");
   Console::WriteLine(S"CHAR    VALUE OF ASSOCIATED PROPERTY, IF ANY\n");
   Console::WriteLine(S"  d {0}", myDT.ToString(S"d"));
   Console::WriteLine(S" {0} {1}\n", myDTFI -&gt; ShortDatePattern, S"(ShortDatePattern)");
   Console::WriteLine(S"  D {0}", myDT.ToString(S"D"));
   Console::WriteLine(S" {0} {1}\n", myDTFI -&gt; LongDatePattern, S"(LongDatePattern)");
   Console::WriteLine(S"  f {0}\n", myDT.ToString(S"f"));
   Console::WriteLine(S"  F {0}", myDT.ToString(S"F"));
   Console::WriteLine(S" {0} {1}\n", myDTFI -&gt; FullDateTimePattern, S"(FullDateTimePattern)");
   Console::WriteLine(S"  g {0}\n", myDT.ToString(S"g"));
   Console::WriteLine(S"  G {0}\n", myDT.ToString(S"G"));
   Console::WriteLine(S"  m {0}", myDT.ToString(S"m"));
   Console::WriteLine(S" {0} {1}\n", myDTFI -&gt; MonthDayPattern, S"(MonthDayPattern)");
   Console::WriteLine(S"  M {0}", myDT.ToString(S"M"));
   Console::WriteLine(S" {0} {1}\n", myDTFI -&gt; MonthDayPattern, S"(MonthDayPattern)");
   Console::WriteLine(S"  r {0}", myDT.ToString(S"r"));
   Console::WriteLine(S" {0} {1}\n", myDTFI -&gt; RFC1123Pattern, S"(RFC1123Pattern)");
   Console::WriteLine(S"  R {0}", myDT.ToString(S"R"));
   Console::WriteLine(S" {0} {1}\n", myDTFI -&gt; RFC1123Pattern, S"(RFC1123Pattern)");
   Console::WriteLine(S"  s {0}", myDT.ToString(S"s"));
   Console::WriteLine(S" {0} {1}\n", myDTFI -&gt; SortableDateTimePattern, S"(SortableDateTimePattern)");
   Console::WriteLine(S"  t {0}", myDT.ToString(S"t"));
   Console::WriteLine(S" {0} {1}\n", myDTFI -&gt; ShortTimePattern, S"(ShortTimePattern)");
   Console::WriteLine(S"  T {0}", myDT.ToString(S"T"));
   Console::WriteLine(S" {0} {1}\n", myDTFI -&gt; LongTimePattern, S"(LongTimePattern)");
   Console::WriteLine(S"  u {0}", myDT.ToString(S"u"));
   Console::WriteLine(S" {0} {1}\n", myDTFI -&gt; UniversalSortableDateTimePattern, S"(UniversalSortableDateTimePattern)");
   Console::WriteLine(S"  U {0}\n", myDT.ToString(S"U"));
   Console::WriteLine(S"  y {0}", myDT.ToString(S"y"));
   Console::WriteLine(S" {0} {1}\n", myDTFI -&gt; YearMonthPattern, S"(YearMonthPattern)");
   Console::WriteLine(S"  Y {0}", myDT.ToString(S"Y"));
   Console::WriteLine(S" {0} {1}\n", myDTFI -&gt; YearMonthPattern, S"(YearMonthPattern)");
}

/*
This code produces the following output.

FORMAT  en-US EXAMPLE
CHAR    VALUE OF ASSOCIATED PROPERTY, IF ANY

d     1/3/2002
M/d/yyyy (ShortDatePattern)

D     Thursday, January 03, 2002
dddd, MMMM dd, yyyy (LongDatePattern)

f     Thursday, January 03, 2002 12:00 AM

F     Thursday, January 03, 2002 12:00:00 AM
dddd, MMMM dd, yyyy h:mm:ss tt (FullDateTimePattern)

g     1/3/2002 12:00 AM

G     1/3/2002 12:00:00 AM

m     January 03
MMMM dd (MonthDayPattern)

M     January 03
MMMM dd (MonthDayPattern)

r     Thu, 03 Jan 2002 00:00:00 GMT
ddd, dd MMM yyyy HH':'mm':'ss 'GMT' (RFC1123Pattern)

R     Thu, 03 Jan 2002 00:00:00 GMT
ddd, dd MMM yyyy HH':'mm':'ss 'GMT' (RFC1123Pattern)

s     2002-01-03T00:00:00
yyyy'-'MM'-'dd'T'HH':'mm':'ss (SortableDateTimePattern)

t     12:00 AM
h:mm tt (ShortTimePattern)

T     12:00:00 AM
h:mm:ss tt (LongTimePattern)

u     2002-01-03 00:00:00Z
yyyy'-'MM'-'dd HH':'mm':'ss'Z' (UniversalSortableDateTimePattern)

U     Thursday, January 03, 2002 8:00:00 AM

y     January, 2002
MMMM, yyyy (YearMonthPattern)

Y     January, 2002
MMMM, yyyy (YearMonthPattern)

*/</pre>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/balaramesht.wordpress.com/26/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/balaramesht.wordpress.com/26/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/balaramesht.wordpress.com/26/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/balaramesht.wordpress.com/26/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/balaramesht.wordpress.com/26/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/balaramesht.wordpress.com/26/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/balaramesht.wordpress.com/26/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/balaramesht.wordpress.com/26/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/balaramesht.wordpress.com/26/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/balaramesht.wordpress.com/26/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/balaramesht.wordpress.com/26/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/balaramesht.wordpress.com/26/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/balaramesht.wordpress.com/26/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/balaramesht.wordpress.com/26/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=balaramesht.wordpress.com&amp;blog=10211564&amp;post=26&amp;subd=balaramesht&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://balaramesht.wordpress.com/2009/11/04/datetimeformatinfo-class/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c8b0670188b175256018b1a9afa46b1?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">balaramesht</media:title>
		</media:content>
	</item>
		<item>
		<title>create and maintain robots.txt for a website</title>
		<link>http://balaramesht.wordpress.com/2009/11/03/create-and-maintain-robots-txt-for-a-website/</link>
		<comments>http://balaramesht.wordpress.com/2009/11/03/create-and-maintain-robots-txt-for-a-website/#comments</comments>
		<pubDate>Tue, 03 Nov 2009 16:04:53 +0000</pubDate>
		<dc:creator>balaramesht</dc:creator>
				<category><![CDATA[WebSite Hosting]]></category>
		<category><![CDATA[create robots.txt for a web site]]></category>
		<category><![CDATA[define:robots.tx]]></category>
		<category><![CDATA[Introduction to "robots.txt"]]></category>
		<category><![CDATA[Robots exclusion standard]]></category>
		<category><![CDATA[robots txt checker]]></category>
		<category><![CDATA[robots txt directives]]></category>
		<category><![CDATA[robots txt exclusion]]></category>
		<category><![CDATA[robots txt ignore]]></category>
		<category><![CDATA[robots txt meta tag]]></category>
		<category><![CDATA[robots txt sitemaps]]></category>
		<category><![CDATA[robots txt wildcard]]></category>
		<category><![CDATA[Robots.txt Generator]]></category>
		<category><![CDATA[Robotstxt]]></category>
		<category><![CDATA[What is Robots.txt]]></category>

		<guid isPermaLink="false">http://balaramesht.wordpress.com/?p=20</guid>
		<description><![CDATA[About /robots.txt In a nutshell Web site owners use the /robots.txt file to give instructions about their site to web robots; this is called The Robots Exclusion Protocol. It works likes this: a robot wants to vists a Web site &#8230; <a href="http://balaramesht.wordpress.com/2009/11/03/create-and-maintain-robots-txt-for-a-website/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=balaramesht.wordpress.com&amp;blog=10211564&amp;post=20&amp;subd=balaramesht&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<h2>About /robots.txt</h2>
<h3>In a nutshell</h3>
<p>Web site owners use the /robots.txt file to give instructions about their site to web robots; this is called <em>The Robots Exclusion Protocol</em>.</p>
<p>It works likes this: a robot wants to vists a Web site URL, say http://www.example.com/welcome.html. Before it does so, it firsts checks for http://www.example.com/robots.txt, and finds:</p>
<pre>User-agent: *
Disallow: /</pre>
<p>The &#8220;<tt>User-agent: *</tt>&#8221; means this section applies to all robots. The &#8220;<tt>Disallow: /</tt>&#8221; tells the robot that it should not visit any pages on the site.</p>
<p>There are two important considerations when using /robots.txt:</p>
<ul>
<li>robots can ignore your /robots.txt. Especially malware robots that scan the web for security vulnerabilities, and email address harvesters used by spammers will pay no attention.</li>
<li>the /robots.txt file is a publicly available file. Anyone can see what sections of your server you don&#8217;t want robots to use.</li>
</ul>
<p>So don&#8217;t try to use /robots.txt to hide information.</p>
<p>See also:</p>
<ul>
<li><a href="http://www.robotstxt.org/faq/blockjustbad.html">Can I block just bad robots?</a></li>
<li><a href="http://www.robotstxt.org/faq/ignore.html">Why did this robot ignore my /robots.txt?</a></li>
<li><a href="http://www.robotstxt.org/faq/nosecurity.html">What are the security implications of /robots.txt?</a></li>
</ul>
<h3>The details</h3>
<p>The /robots.txt is a de-facto standard, and is not owned by any standards body. There are two historical descriptions:</p>
<ul>
<li>the original 1994 <a href="http://www.robotstxt.org/orig.html">A Standard for Robot Exclusion</a> document.</li>
<li>a 1997 Internet Draft specification <a href="http://www.robotstxt.org/norobots-rfc.txt">A Method for Web Robots Control</a></li>
</ul>
<p>In addition there are external resources:</p>
<ul>
<li><a href="http://www.w3.org/TR/html4/appendix/notes.html#h-B.4.1.1">HTML 4.01 specification, Appendix B.4.1</a></li>
<li><a href="http://en.wikipedia.org/wiki/Robots.txt">Wikipedia &#8211; Robots Exclusion Standard</a></li>
</ul>
<p>The /robots.txt standard is not actively developed. See <a href="http://www.robotstxt.org/faq/future.html">What about further development of /robots.txt?</a> for more discussion.</p>
<p>The rest of this page gives an overview of how to use /robots.txt on your server, with some simple recipes. To learn more see also the <a href="http://www.robotstxt.org/faq.html">FAQ</a>.</p>
<h3>How to create a /robots.txt file</h3>
<h4>Where to put it</h4>
<p>The short answer: in the top-level directory of your web server.</p>
<p>The longer answer:</p>
<p>When a robot looks for the &#8220;/robots.txt&#8221; file for URL, it strips the path component from the URL (everything from the first single slash), and puts &#8220;/robots.txt&#8221; in its place.</p>
<p>For example, for &#8220;<tt>http://www.example.com/shop/index.html</tt>, it will remove the &#8220;<tt>/shop/index.html</tt>&#8220;, and replace it with &#8220;<tt>/robots.txt</tt>&#8220;, and will end up with &#8220;http://www.example.com/robots.txt&#8221;.</p>
<p>So, as a web site owner you need to put it in the right place on your web server for that resulting URL to work. Usually that is the same place where you put your web site&#8217;s main &#8220;<tt>index.html</tt>&#8221; welcome page. Where exactly that is, and how to put the file there, depends on your web server software.</p>
<p>Remember to use all lower case for the filename: &#8220;<tt>robots.txt</tt>&#8220;, not &#8220;<tt>Robots.TXT</tt>.</p>
<p>See also:</p>
<ul>
<li><a href="http://www.robotstxt.org/faq/editor.html">What program should I use to create /robots.txt?</a></li>
<li><a href="http://www.robotstxt.org/faq/virtual.html">How do I use /robots.txt on a virtual host?</a></li>
<li><a href="http://www.robotstxt.org/faq/shared.html">How do I use /robots.txt on a shared host?</a></li>
</ul>
<h4>What to put in it</h4>
<p>The &#8220;/robots.txt&#8221; file is a text file, with one or more records. Usually contains a single record looking like this:</p>
<pre>User-agent: *
Disallow: /cgi-bin/
Disallow: /tmp/
Disallow: /~joe/</pre>
<p>In this example, three directories are excluded.</p>
<p>Note that you need a separate &#8220;Disallow&#8221; line for every URL prefix you want to exclude &#8212; you cannot say &#8220;Disallow: /cgi-bin/ /tmp/&#8221; on a single line. Also, you may not have blank lines in a record, as they are used to delimit multiple records.</p>
<p>Note also that globbing and regular expression are <strong>not</strong> supported in either the User-agent or Disallow lines. The &#8216;*&#8217; in the User-agent field is a special value meaning &#8220;any robot&#8221;. Specifically, you cannot have lines like &#8220;User-agent: *bot*&#8221;, &#8220;Disallow: /tmp/*&#8221; or &#8220;Disallow: *.gif&#8221;.</p>
<p>What you want to exclude depends on your server. Everything not explicitly disallowed is considered fair game to retrieve. Here follow some examples:</p>
<h5>To exclude all robots from the entire server</h5>
<pre>User-agent: *
Disallow: /</pre>
<h5>To allow all robots complete access</h5>
<pre>User-agent: *
Disallow:</pre>
<p>(or just create an empty &#8220;/robots.txt&#8221; file, or don&#8217;t use one at all)</p>
<h5>To exclude all robots from part of the server</h5>
<pre>User-agent: *
Disallow: /cgi-bin/
Disallow: /tmp/
Disallow: /junk/</pre>
<h5>To exclude a single robot</h5>
<pre>User-agent: BadBot
Disallow: /</pre>
<h5>To allow a single robot</h5>
<pre>User-agent: Google
Disallow:

User-agent: *
Disallow: /</pre>
<h5>To exclude all files except one</h5>
<p>This is currently a bit awkward, as there is no &#8220;Allow&#8221; field. The easy way is to put all files to be disallowed into a separate directory, say &#8220;stuff&#8221;, and leave the one file in the level above this directory:</p>
<pre>User-agent: *
Disallow: /~joe/stuff/</pre>
<p>Alternatively you can explicitly disallow all disallowed pages:</p>
<pre>User-agent: *
Disallow: /~joe/junk.html
Disallow: /~joe/foo.html
Disallow: /~joe/bar.html

<strong>Examples</strong>

This example <strong>allows all robots</strong> to visit <strong>all files</strong> because the wildcard "*" specifies all robots:

User-agent: *

Disallow:

This example keeps <strong>all robots out</strong>:

User-agent: *

Disallow: /

The next is an example that tells <strong>all crawlers</strong> not to enter four directories of a website:

User-agent: *

Disallow: /cgi-bin/

Disallow: /images/

Disallow: /tmp/

Disallow: /private/

Example that tells <strong>a specific crawler</strong> not to enter one specific directory:

User-agent: BadBot # replace the 'BadBot' with the actual user-agent of the bot

Disallow: /private/

Example that tells <strong>all crawlers</strong> not to enter one specific file:

User-agent: *

Disallow: /directory/file.html

Note that all other files in the specified directory will be processed.

Example demonstrating how comments can be used:

# Comments appear after the "#" symbol at the start of a line, or after a directive

User-agent: * # match all bots

Disallow: / # keep them out

<strong>[<a title="Edit section: Nonstandard extensions" href="http://en.wikipedia.org/w/index.php?title=Robots_exclusion_standard&amp;action=edit&amp;section=6">edit</a>] Nonstandard extensions</strong>

<strong>[<a title="Edit section: Crawl-delay directive" href="http://en.wikipedia.org/w/index.php?title=Robots_exclusion_standard&amp;action=edit&amp;section=7">edit</a>] Crawl-delay directive</strong>

Several major crawlers support a Crawl-delay parameter, set to the number of seconds to wait between successive requests to the same server: <sup><a href="http://en.wikipedia.org/wiki/Robots_exclusion_standard#cite_note-0">[1]</a></sup> <sup><a href="http://en.wikipedia.org/wiki/Robots_exclusion_standard#cite_note-1">[2]</a></sup>

User-agent: *

Crawl-delay: 10

<strong>[<a title="Edit section: Allow directive" href="http://en.wikipedia.org/w/index.php?title=Robots_exclusion_standard&amp;action=edit&amp;section=8">edit</a>] Allow directive</strong>

Some major crawlers support an Allow directive which can counteract a following Disallow directive.<sup><a href="http://en.wikipedia.org/wiki/Robots_exclusion_standard#cite_note-2">[3]</a></sup> <sup><a href="http://en.wikipedia.org/wiki/Robots_exclusion_standard#cite_note-3">[4]</a></sup> This is useful when you disallow an entire directory but still want some HTML documents in that directory crawled and indexed. While by standard implementation the first matching robots.txt pattern always wins, Google's implementation differs in that it first evaluates all Allow patterns and only then all Disallow patterns. Yet, in order to be compatible to all robots, if you want to allow single files inside an otherwise disallowed directory, you need to place the Allow directive(s) first, followed by the Disallow, for example:

Allow: /folder1/myfile.html

Disallow: /folder1/

This example will Disallow anything in /folder1/ except /folder1/myfile.html, since the latter will match first. In case of Google, though, the order is not important.

<strong>[<a title="Edit section: Sitemap" href="http://en.wikipedia.org/w/index.php?title=Robots_exclusion_standard&amp;action=edit&amp;section=9">edit</a>] Sitemap</strong>

Some crawlers support a Sitemap directive, allowing multiple <a title="Sitemaps" href="http://en.wikipedia.org/wiki/Sitemaps">sitemaps</a> in the same robots.txt in the form:<sup><a href="http://en.wikipedia.org/wiki/Robots_exclusion_standard#cite_note-4">[5]</a></sup>

Sitemap: http://www.gstatic.com/s2/sitemaps/profiles-sitemap.xml

Sitemap: http://www.google.com/hostednews/sitemap_index.xml

<strong>[<a title="Edit section: Extended standard" href="http://en.wikipedia.org/w/index.php?title=Robots_exclusion_standard&amp;action=edit&amp;section=10">edit</a>] Extended standard</strong>

An <a href="http://www.conman.org/people/spc/robots2.html">Extended Standard for Robot Exclusion</a> has been proposed, which adds several new directives, such as <strong>Visit-time</strong> and <strong>Request-rate</strong>. For example:

User-agent: *

Disallow: /downloads/

Request-rate: 1/5         # maximum rate is one page every 5 seconds

Visit-time: 0600-0845     # only visit between 06:00 and 08:45 UTC (GMT)

The first version of the Robot Exclusion standard does not mention anything about the "*" character in the Disallow: statement. Some crawlers like Googlebot and Slurp recognize strings containing "*", while MSNbot and Teoma interpret it in different ways.
<h2>Why did this robot ignore my robots.txt in website?</h2>

It could be that it was written by an inexperienced software writer. Occasionally schools set their students "write a web robot" assignments. But, these days it's more likely that the robot is explicitly written to scan your site for information to abuse: it might be collecting email addresses to send email spam, look for forms to post links ("<a href="http://en.wikipedia.org/wiki/Spamdexing">spamdexing</a>"), or security holes to exploit.
<h2>Can I block just bad robots?</h2>

In theory yes, in practice, no. If the bad robot obeys /robots.txt, and you know the name it scans for in the User-Agent field. then you can create a section in your /robotst.txt to exclude it specifically. But almost all bad robots ignore /robots.txt, making that pointless.

If the bad robot operates from a single IP address, you can block its access to your web server through server configuration or with a network firewall.

If copies of the robot operate at lots of different IP addresses, such as hijacked PCs that are part of a large <a href="http://en.wikipedia.org/wiki/Botnet">Botnet</a>, then it becomes more difficult. The best option then is to use advanced firewall rules configuration that automatically block access to IP addresses that make many connections; but that can hit good robots as well your bad robots.

<span id="more-20"></span>
<h2>Robots vs &lt;META&gt; tag</h2>

You can use a special HTML <tt>&lt;META&gt;</tt> tag to tell robots not to index the content of a page, and/or not scan it for links to follow.

For example:
<pre>&lt;html&gt;
&lt;head&gt;
&lt;title&gt;...&lt;/title&gt;
<strong>&lt;META CONTENT="NOINDEX, NOFOLLOW"&gt;</strong>
&lt;/head&gt;</pre>
<p>There are two important considerations when using the robots &lt;META&gt; tag:</p>
<ul>
<li>robots can ignore your &lt;META&gt; tag. Especially malware robots that scan the web for security vulnerabilities, and email address harvesters used by spammers will pay no attention.</li>
<li>the NOFOLLOW directive only applies to links on this page. It's entirely likely that a robot might find the same links on some other page without a NOFOLLOW (perhaps on some other site), and so still arrives at your undesired page.</li>
</ul>
<p>Don't confuse this NOFOLLOW with the <a href="http://www.robotstxt.org/faq/relnofollow.html"><tt>rel="nofollow"</tt> link attribute</a>.</p>
<h3>The details</h3>
<p>Like the <a href="http://www.robotstxt.org/robotstxt.html">/robots.txt</a>, the robots META tag is a de-facto standard. It originated from a "birds of a feather" meeting at a <a href="http://www.w3.org/Search/9605-Indexing-Workshop/">1996 distributed indexing workshop</a>, and was described in <a href="http://www.robotstxt.org/metabof.html">meeting notes</a>.</p>
<p>The META tag is also described in <a href="http://www.w3.org/TR/html401/appendix/notes.html#h-B.4.1.2">the HTML 4.01 specification, Appendix B.4.1</a>.</p>
<p>The rest of this page gives an overview of how to use the robots &lt;META&gt; tags in your pages, with some simple recipes. To learn more see also the <a href="http://www.robotstxt.org/faq.html">FAQ</a>.</p>
<h3>How to write a Robots Meta Tag</h3>
<h4>Where to put it</h4>
<p>Like any &lt;META&gt; tag it should be placed in the HEAD section of an HTML page, as in the example above. You should put it in every page on your site, because a robot can encounter a <a href="http://en.wikipedia.org/wiki/Deep_linking">deep link</a> to any page on your site.</p>
<h4>What to put into it</h4>
<p>The "<tt>NAME</tt>" attribute must be "ROBOTS".</p>
<p>Valid values for the "<tt>CONTENT</tt>" attribute are: "<tt>INDEX</tt>", "<tt>NOINDEX</tt>", "<tt>FOLLOW</tt>", "<tt>NOFOLLOW</tt>". Multiple comma-separated values are allowed, but obviously only some combinations make sense. If there is no robots &lt;META&gt; tag, the default is "<tt>INDEX,FOLLOW</tt>", so there's no need to spell that out. That leaves:</p>
<pre><strong>&lt;META CONTENT="NOINDEX, FOLLOW"&gt;</strong>
<strong>&lt;META CONTENT="INDEX, NOFOLLOW"&gt;</strong>
<strong>&lt;META CONTENT="NOINDEX, NOFOLLOW"&gt;</strong></pre>
<p>&nbsp;</p>
</pre>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/balaramesht.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/balaramesht.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/balaramesht.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/balaramesht.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/balaramesht.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/balaramesht.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/balaramesht.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/balaramesht.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/balaramesht.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/balaramesht.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/balaramesht.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/balaramesht.wordpress.com/20/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/balaramesht.wordpress.com/20/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/balaramesht.wordpress.com/20/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=balaramesht.wordpress.com&amp;blog=10211564&amp;post=20&amp;subd=balaramesht&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://balaramesht.wordpress.com/2009/11/03/create-and-maintain-robots-txt-for-a-website/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c8b0670188b175256018b1a9afa46b1?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">balaramesht</media:title>
		</media:content>
	</item>
		<item>
		<title>Store proc in T-SQL SERVER 2005</title>
		<link>http://balaramesht.wordpress.com/2009/10/31/store-proc-in-t-sql-server-2005/</link>
		<comments>http://balaramesht.wordpress.com/2009/10/31/store-proc-in-t-sql-server-2005/#comments</comments>
		<pubDate>Sat, 31 Oct 2009 18:20:48 +0000</pubDate>
		<dc:creator>balaramesht</dc:creator>
				<category><![CDATA[Store Procedure]]></category>
		<category><![CDATA[1 Stored Procedures in T-SQL 2 T-SQL]]></category>
		<category><![CDATA[ADO.NET calling T-SQL Stored Procedure]]></category>
		<category><![CDATA[Book results for store proc in TSQL]]></category>
		<category><![CDATA[CREATE PROCEDURE (T-SQL)]]></category>
		<category><![CDATA[Creating Stored Procedures (Database Engine)]]></category>
		<category><![CDATA[Microsoft SQL Server 2005 Stored Procedure ...]]></category>
		<category><![CDATA[Sample T-SQL stored procedure]]></category>
		<category><![CDATA[stored proc in SQL]]></category>
		<category><![CDATA[Stored Procedures: An Overview]]></category>
		<category><![CDATA[[T-SQL] Call a stored procedure once for each row in a query]]></category>

		<guid isPermaLink="false">http://balaramesht.wordpress.com/?p=17</guid>
		<description><![CDATA[Microsoft SQL Server provides the stored procedure mechanism to simplify the database development process by grouping Transact-SQL statements into manageable blocks. Benefits of Stored Procedures Why should you use stored procedures? Let&#8217;s take a look at the key benefits of &#8230; <a href="http://balaramesht.wordpress.com/2009/10/31/store-proc-in-t-sql-server-2005/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=balaramesht.wordpress.com&amp;blog=10211564&amp;post=17&amp;subd=balaramesht&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Microsoft <a href="http://databases.about.com/library/glossary/bldef-sqlserver.htm">SQL Server</a> provides the <a href="http://databases.about.com/od/specificproducts/g/storedprocedure.htm">stored procedure</a> mechanism to simplify the database development process by grouping <a href="http://databases.about.com/od/sqlserver/g/transactsql.htm">Transact-SQL</a> statements into manageable blocks.</p>
<h3>Benefits of Stored Procedures</h3>
<p>Why should you use stored procedures? Let&#8217;s take a look at the key benefits of this technology:</p>
<ul>
<li><strong>Precompiled execution</strong>. SQL Server compiles each stored procedure once and then reutilizes the execution plan. This results in tremendous performance boosts when stored procedures are called repeatedly.</li>
<li><strong>Reduced client/server traffic</strong>. If network bandwidth is a concern in your environment, you&#8217;ll be happy to learn that stored procedures can reduce long <a href="http://databases.about.com/library/glossary/bldef-query.htm">SQL queries</a> to a single line that is transmitted over the wire.</li>
<li><strong>Efficient reuse of code and programming abstraction</strong>. Stored procedures can be used by multiple users and client programs. If you utilize them in a planned manner, you&#8217;ll find the development cycle takes less time.</li>
<li><strong>Enhanced security controls</strong>. You can grant users permission to execute a stored procedure independently of underlying <a href="http://databases.about.com/library/glossary/bldef-table.htm">table</a> permissions.</li>
</ul>
<p>Stored procedures are very similar to user-defined functions, but there are subtle differences. For more information, read <a href="http://databases.about.com/od/sqlserver/a/procs_vs_functs.htm">Comparing Stored Procedures and User-Defined Functions</a>.</p>
<h3>Structure</h3>
<p>Stored procedures are extremely similar to the constructs seen in other programming languages. They accept data in the form of input parameters that are specified at execution time. These input parameters (if implemented) are utilized in the execution of a series of statements that produce some result. This result is returned to the calling environment through the use of a <a href="http://databases.about.com/library/glossary/bldef-record.htm">recordset</a>, output parameters and a return code. That may sound like a mouthful, but you&#8217;ll find that stored procedures are actually quite simple.</p>
<h3>Example</h3>
<p>Let&#8217;s take a look at a practical example. Assume we have the table shown at the bottom of this page, named Inventory. This information is updated in real-time and warehouse managers are constantly checking the levels of products stored at their warehouse and available for shipment. In the past, each manager would run queries similar to the following:</p>
<blockquote class="no"><p>SELECT Product, Quantity<br />
FROM Inventory<br />
WHERE Warehouse = &#8216;FL&#8217;</p></blockquote>
<p>This resulted in very inefficient performance at the SQL Server. Each time a warehouse manager executed the query, the database server was forced to recompile the query and execute it from scratch. It also required the warehouse manager to have knowledge of SQL and appropriate permissions to access the table information.</p>
<p>We can simplify this process through the use of a stored procedure. Let&#8217;s create a procedure called sp_GetInventory that retrieves the inventory levels for a given warehouse. Here&#8217;s the SQL code:</p>
<blockquote class="no"><p>CREATE PROCEDURE sp_GetInventory<br />
@location varchar(10)<br />
AS<br />
SELECT Product, Quantity<br />
FROM Inventory<br />
WHERE Warehouse = @location</p></blockquote>
<p>Our Florida warehouse manager can then access inventory levels by issuing the command</p>
<blockquote class="no"><p>EXECUTE sp_GetInventory &#8216;FL&#8217;</p></blockquote>
<p>The New York warehouse manager can use the same stored procedure to access that area&#8217;s inventory.</p>
<blockquote class="no"><p>EXECUTE sp_GetInventory &#8216;NY&#8217;</p></blockquote>
<p>Granted, this is a simple example, but the benefits of abstraction can be seen here. The warehouse manager does not need to understand SQL or the inner workings of the procedure. From a performance perspective, the stored procedure will work wonders. The SQL Sever creates an execution plan once and then reutilizes it by plugging in the appropriate parameters at execution time.</p>
<p>Now that you&#8217;ve learned the benefits of stored procedures, get out there and use them! Try a few examples and measure the performance enhancements achieved &#8212; you&#8217;ll be amazed!</p>
<h3>Inventory Table</h3>
<table border="0" cellspacing="0" cellpadding="0" width="425" align="center">
<tbody>
<tr>
<td><strong>ID</strong></td>
<td><strong>Product</strong></td>
<td><strong>Warehouse</strong></td>
<td><strong>Quantity</strong></td>
</tr>
<tr>
<td>142</td>
<td>Green beans</td>
<td>NY</td>
<td>100</td>
</tr>
<tr>
<td>214</td>
<td>Peas</td>
<td>FL</td>
<td>200</td>
</tr>
<tr>
<td>825</td>
<td>Corn</td>
<td>NY</td>
<td>140</td>
</tr>
<tr>
<td>512</td>
<td>Lima beans</td>
<td>NY</td>
<td>180</td>
</tr>
<tr>
<td>491</td>
<td>Tomatoes</td>
<td>FL</td>
<td>80</td>
</tr>
<tr>
<td>379</td>
<td>Watermelon</td>
<td>FL</td>
<td>85</td>
</tr>
</tbody>
</table>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>This article covers the basic of writing a stored procedure. It&#8217;s the first in a series on writing stored procedures.</p>
<p>&lt;!&#8211;<br />
<hr />&#8211;&gt;</p>
<div id="article_body">A stored procedure is written using Transact-SQL (T-SQL). T-SQL is a subset of ANSI SQL-92 that has extensions to the Standard. T-SQL includes variables, conditional logic, loops and flow control. We&#8217;ll use the pubs database for our examples. A stored procedure allows you to put code or business logic on the database server.</p>
<p>A stored procedure allows for more modular programming. You can create reusable, discrete pieces of functionality using stored procedures. Stored procedures have the parsing and execution plan built at the time they are created so they execute faster than dynamic SQL. If you have a stored procedure that manipulates large amounts of data, that data will remain on the server and not be transported across the network. You can also use stored procedures for security. You can grant users execute permissions on stored procedures without granting them permissions on objects manipulated by those stored procedures.</p>
<p>You can use SQL Server&#8217;s Enterprise Manager to create and edit stored procedures. A simple stored procedure looks like:</p>
<blockquote><p><code>CREATE PROCEDURE spCaliforniaAuthors<br />
AS<br />
SELECT * FROM authors<br />
WHERE state = 'CA'<br />
ORDER BY zip</code></p></blockquote>
<p>This stored procedure is called &#8220;spCaliforniaAuthors&#8221;. All it contains is a SELECT statement. All stored procedures that SQL Server provides start with &#8220;sp_&#8221; (and &#8220;xp_&#8221; for extended stored procedures) and I chose to almost follow this convention for this stored procedure. If you try to call a stored procedure that starts with &#8220;sp_&#8221; SQL Server will first search the MASTER database before searching the current database.</p>
<p>By default, only members of the dbo_owner role and db_ddladmin role can create stored procedures. Members of the dbo_owner role can give other users the ability to create procedures using a GRANT statement. That might look something like this:</p>
<blockquote><p><code>GRANT CREATE PROCEDURE TO Development</code></p></blockquote>
<p>You can check Books Online for more information on the GRANT statement.</p>
<p>You execute a stored procedure by typing it&#8217;s name or using the EXECUTE statement. To execute our stored procedure you can type</p>
<blockquote><p><code>EXECUTE spCaliforniaAuthors</code></p></blockquote>
<p>This will execute the stored procedure and return the results. If you are calling this procedure from an ASP page (or other client) you can use the EXECUTE statement as you SQL string to execute. In this case, our stored procedure will return a record set.</p></div>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/balaramesht.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/balaramesht.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/balaramesht.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/balaramesht.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/balaramesht.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/balaramesht.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/balaramesht.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/balaramesht.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/balaramesht.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/balaramesht.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/balaramesht.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/balaramesht.wordpress.com/17/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/balaramesht.wordpress.com/17/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/balaramesht.wordpress.com/17/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=balaramesht.wordpress.com&amp;blog=10211564&amp;post=17&amp;subd=balaramesht&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://balaramesht.wordpress.com/2009/10/31/store-proc-in-t-sql-server-2005/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c8b0670188b175256018b1a9afa46b1?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">balaramesht</media:title>
		</media:content>
	</item>
		<item>
		<title>company announcements in UK</title>
		<link>http://balaramesht.wordpress.com/2009/10/31/company-announcements-in-uk/</link>
		<comments>http://balaramesht.wordpress.com/2009/10/31/company-announcements-in-uk/#comments</comments>
		<pubDate>Sat, 31 Oct 2009 18:12:43 +0000</pubDate>
		<dc:creator>balaramesht</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://balaramesht.wordpress.com/2009/10/31/company-announcements-in-uk/</guid>
		<description><![CDATA[investEgate<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=balaramesht.wordpress.com&amp;blog=10211564&amp;post=13&amp;subd=balaramesht&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.investEgate.co.uk">investEgate</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/balaramesht.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/balaramesht.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/balaramesht.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/balaramesht.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/balaramesht.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/balaramesht.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/balaramesht.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/balaramesht.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/balaramesht.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/balaramesht.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/balaramesht.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/balaramesht.wordpress.com/13/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/balaramesht.wordpress.com/13/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/balaramesht.wordpress.com/13/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=balaramesht.wordpress.com&amp;blog=10211564&amp;post=13&amp;subd=balaramesht&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://balaramesht.wordpress.com/2009/10/31/company-announcements-in-uk/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c8b0670188b175256018b1a9afa46b1?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">balaramesht</media:title>
		</media:content>
	</item>
		<item>
		<title>javascript Date functions</title>
		<link>http://balaramesht.wordpress.com/2009/10/31/javascript-date-functions/</link>
		<comments>http://balaramesht.wordpress.com/2009/10/31/javascript-date-functions/#comments</comments>
		<pubDate>Sat, 31 Oct 2009 18:06:55 +0000</pubDate>
		<dc:creator>balaramesht</dc:creator>
				<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Basic JavaScript Date and Time Functions]]></category>
		<category><![CDATA[JavaScript Date and Time Functions]]></category>
		<category><![CDATA[JavaScript Date Object]]></category>
		<category><![CDATA[javascript date object getmonth]]></category>
		<category><![CDATA[javascript date object getyear]]></category>
		<category><![CDATA[javascript getdate function]]></category>
		<category><![CDATA[javascript getday function]]></category>
		<category><![CDATA[JavaScript Toolbox - Date Formatting And Format Validation Functions]]></category>
		<category><![CDATA[Javascript Tutorial - Date]]></category>

		<guid isPermaLink="false">http://balaramesht.wordpress.com/?p=11</guid>
		<description><![CDATA[<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=balaramesht.wordpress.com&amp;blog=10211564&amp;post=11&amp;subd=balaramesht&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=balaramesht.wordpress.com&amp;blog=10211564&amp;post=11&amp;subd=balaramesht&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://balaramesht.wordpress.com/2009/10/31/javascript-date-functions/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c8b0670188b175256018b1a9afa46b1?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">balaramesht</media:title>
		</media:content>
	</item>
		<item>
		<title>javascript string functions</title>
		<link>http://balaramesht.wordpress.com/2009/10/31/javascript-string-functions/</link>
		<comments>http://balaramesht.wordpress.com/2009/10/31/javascript-string-functions/#comments</comments>
		<pubDate>Sat, 31 Oct 2009 17:43:51 +0000</pubDate>
		<dc:creator>balaramesht</dc:creator>
				<category><![CDATA[Javascript]]></category>
		<category><![CDATA[JavaScript - Strings]]></category>
		<category><![CDATA[Javascript string Function]]></category>
		<category><![CDATA[javascript string functions]]></category>
		<category><![CDATA[javascript string functions replace]]></category>
		<category><![CDATA[javascript string functions trim]]></category>
		<category><![CDATA[JavaScript String Object]]></category>
		<category><![CDATA[JavaScript string tutorial]]></category>
		<category><![CDATA[Javascript Tutorial - Strings]]></category>
		<category><![CDATA[String functions in JavaScript]]></category>
		<category><![CDATA[Useful JavaScript String Functions: ASP Alliance]]></category>

		<guid isPermaLink="false">http://balaramesht.wordpress.com/?p=5</guid>
		<description><![CDATA[Syntax var myStr=new String(string); String Object Properties F: Firefox, IE: Internet Explorer Property Description F IE constructor Returns a reference to the function that created the object 1 4 length Returns the number of characters in a string 1 3 &#8230; <a href="http://balaramesht.wordpress.com/2009/10/31/javascript-string-functions/">Continue reading <span class="meta-nav">&#8594;</span></a><img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=balaramesht.wordpress.com&amp;blog=10211564&amp;post=5&amp;subd=balaramesht&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<h2>Syntax</h2>
<table border="0" cellspacing="0" cellpadding="0" width="100%">
<tbody>
<tr>
<td>var myStr=new String(string);</td>
</tr>
</tbody>
</table>
<h2>String Object Properties</h2>
<p><strong>F:</strong> Firefox, <strong>IE:</strong> Internet Explorer</p>
<table border="1" cellspacing="0" cellpadding="0" width="100%">
<tbody>
<tr>
<th width="23%" align="left" valign="top">Property</th>
<th width="69%" align="left" valign="top">Description</th>
<th width="4%" align="left" valign="top">F</th>
<th width="4%" align="left" valign="top">IE</th>
</tr>
<tr>
<td valign="top"><a href="jsref_constructor_string.asp">constructor</a></td>
<td valign="top">Returns a reference to the function that created the object</td>
<td valign="top">1</td>
<td valign="top">4</td>
</tr>
<tr>
<td valign="top"><a href="jsref_length_string.asp">length</a></td>
<td valign="top">Returns the number of characters in a string</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_prototype_string.asp">prototype</a></td>
<td valign="top">Allows you to add properties and methods to an object</td>
<td valign="top">1</td>
<td valign="top">4</td>
</tr>
</tbody>
</table>
<h2>String HTML Wrapper Methods</h2>
<p>The HTML wrapper methods return the string wrapped inside the appropriate HTML tag.</p>
<table border="1" cellspacing="0" cellpadding="0" width="100%">
<tbody>
<tr>
<th width="23%" align="left" valign="top">Method</th>
<th width="69%" align="left" valign="top">Description</th>
<th width="4%" align="left" valign="top">F</th>
<th width="4%" align="left" valign="top">IE</th>
</tr>
<tr>
<td valign="top"><a href="jsref_anchor.asp">anchor()</a></td>
<td valign="top">Creates an HTML anchor</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_big.asp">big()</a></td>
<td valign="top">Creates a string in a big font</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_blink.asp">blink()</a></td>
<td valign="top">Creates a blinking string</td>
<td valign="top">1</td>
<td valign="top"> </td>
</tr>
<tr>
<td valign="top"><a href="jsref_bold.asp">bold()</a></td>
<td valign="top">Creates a string in bold</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_fixed.asp">fixed()</a></td>
<td valign="top">Creates a string as teletype text</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_fontcolor.asp">fontcolor()</a></td>
<td valign="top">Creates a string in a specified color</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_fontsize.asp">fontsize()</a></td>
<td valign="top">Creates a string in a specified size</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_italics.asp">italics()</a></td>
<td valign="top">Creates a string in italic</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_link.asp">link()</a></td>
<td valign="top">Creates a string as a hyperlink</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_small.asp">small()</a></td>
<td valign="top">Creates a string in a small font</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_strike.asp">strike()</a></td>
<td valign="top">Creates a string with a strikethrough</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_sub.asp">sub()</a></td>
<td valign="top">Creates a string as subscript</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_sup.asp">sup()</a></td>
<td valign="top">Creates a string as superscript</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
</tbody>
</table>
<h2>String Object Methods</h2>
<table border="1" cellspacing="0" cellpadding="0" width="100%">
<tbody>
<tr>
<th width="23%" align="left" valign="top">Method</th>
<th width="69%" align="left" valign="top">Description</th>
<th width="4%" align="left" valign="top">F</th>
<th width="4%" align="left" valign="top">IE</th>
</tr>
<tr>
<td valign="top"><a href="jsref_charat.asp">charAt()</a></td>
<td valign="top">Returns the character at the specified position in a string</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_charcodeat.asp">charCodeAt()</a></td>
<td valign="top">Returns the Unicode of the character at the specified position in a string</td>
<td valign="top">1</td>
<td valign="top">4</td>
</tr>
<tr>
<td valign="top"><a href="jsref_concat_string.asp">concat()</a></td>
<td valign="top">Joins two or more strings</td>
<td valign="top">1</td>
<td valign="top">4</td>
</tr>
<tr>
<td valign="top"><a href="jsref_fromcharcode.asp">fromCharCode()</a></td>
<td valign="top">Converts Unicode values to characters</td>
<td valign="top">1</td>
<td valign="top">4</td>
</tr>
<tr>
<td valign="top"><a href="jsref_indexof.asp">indexOf()</a></td>
<td valign="top">Returns the position of the first found occurrence of a specified value in a string</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_lastindexof.asp">lastIndexOf()</a></td>
<td valign="top">Returns the position of the last found occurrence of a specified value in a string</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_match.asp">match()</a></td>
<td valign="top">Searches for a match between a regular expression and a string, and returns the matches</td>
<td valign="top">1</td>
<td valign="top">4</td>
</tr>
<tr>
<td valign="top"><a href="jsref_replace.asp">replace()</a></td>
<td valign="top">Searches for a match between a substring (or regular expression) and a string, and replaces the matched substring with a new substring</td>
<td valign="top">1</td>
<td valign="top">4</td>
</tr>
<tr>
<td valign="top"><a href="jsref_search.asp">search()</a></td>
<td valign="top">Searches for a match between a regular expression and a string, and returns the position of the match</td>
<td valign="top">1</td>
<td valign="top">4</td>
</tr>
<tr>
<td valign="top"><a href="jsref_slice_string.asp">slice()</a></td>
<td valign="top">Extracts a part of a string and returns a new string</td>
<td valign="top">1</td>
<td valign="top">4</td>
</tr>
<tr>
<td valign="top"><a href="jsref_split.asp">split()</a></td>
<td valign="top">Splits a string into an array of substrings</td>
<td valign="top">1</td>
<td valign="top">4</td>
</tr>
<tr>
<td valign="top"><a href="jsref_substr.asp">substr()</a></td>
<td valign="top">Extracts a specified number of characters in a string</td>
<td valign="top">1</td>
<td valign="top">4</td>
</tr>
<tr>
<td valign="top"><a href="jsref_substring.asp">substring()</a></td>
<td valign="top">Extracts the characters in a string between two specified indices</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_tolowercase.asp">toLowerCase()</a></td>
<td valign="top">Converts a string to lowercase letters</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_touppercase.asp">toUpperCase()</a></td>
<td valign="top">Converts a string to uppercase letters</td>
<td valign="top">1</td>
<td valign="top">3</td>
</tr>
<tr>
<td valign="top"><a href="jsref_tosource_string.asp">toSource()</a></td>
<td valign="top">Represents the source code of an object</td>
<td valign="top">1</td>
<td valign="top">-</td>
</tr>
<tr>
<td valign="top"><a href="jsref_valueof_string.asp">valueOf()</a></td>
<td valign="top">Returns the primitive value of a String object</td>
<td valign="top">1</td>
<td valign="top">4</td>
</tr>
</tbody>
</table>
<p>JavaScript replace() Method</p>
<h2>Definition and Usage</h2>
<p>The replace() method finds a match between a substring (or regular expression) and a string, and replaces the matched substring with a new substring.</p>
<h2>Syntax</h2>
<table border="0" cellspacing="0" cellpadding="0" width="100%">
<tbody>
<tr>
<td>stringObject.replace(<em>regexp/substr,newstring</em>)</td>
</tr>
</tbody>
</table>
<table border="1" cellspacing="0" cellpadding="0" width="100%">
<tbody>
<tr>
<th width="20%" align="left" valign="top">Parameter</th>
<th width="80%" align="left" valign="top">Description</th>
</tr>
<tr>
<td valign="top">regexp/substr</td>
<td valign="top">Required. A substring or a regular expression object. <a href="jsref_obj_regexp.asp">Read more about the RegExp object</a></td>
</tr>
<tr>
<td valign="top">newstring</td>
<td valign="top">Required. The string to replace the found value in parameter 1</td>
</tr>
</tbody>
</table>
<h2>Example 1</h2>
<p>Perform a case-sensitive search:</p>
<table border="0" cellspacing="0" cellpadding="0" width="100%">
<tbody>
<tr>
<td>&lt;script type=&#8221;text/javascript&#8221;&gt;var str=&#8221;Say GoodMorning!&#8221;;<br />
document.write(str.replace(&#8220;GoodMorning&#8221;, &#8220;HelloWorld&#8221;));</p>
<p>&lt;/script&gt;</td>
</tr>
</tbody>
</table>
<p>The output of the code above will be:</p>
<table border="0" cellspacing="0" cellpadding="0" width="100%">
<tbody>
<tr>
<td>Say Hello World!</td>
</tr>
</tbody>
</table>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/balaramesht.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/balaramesht.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/balaramesht.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/balaramesht.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/balaramesht.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/balaramesht.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/balaramesht.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/balaramesht.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/balaramesht.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/balaramesht.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/balaramesht.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/balaramesht.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/balaramesht.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/balaramesht.wordpress.com/5/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=balaramesht.wordpress.com&amp;blog=10211564&amp;post=5&amp;subd=balaramesht&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://balaramesht.wordpress.com/2009/10/31/javascript-string-functions/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/2c8b0670188b175256018b1a9afa46b1?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">balaramesht</media:title>
		</media:content>
	</item>
	</channel>
</rss>
