<?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/"
	>

<channel>
	<title>Web Development Blog &#187; Google services</title>
	<atom:link href="http://www.web-development-blog.com/archives/category/google-services/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.web-development-blog.com</link>
	<description>Web development tutorials, SEO articles and PHP script resources</description>
	<lastBuildDate>Wed, 25 Aug 2010 19:46:22 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Facebook tips for more efficiency and &#8220;fun&#8221;</title>
		<link>http://www.web-development-blog.com/archives/facebook-tips-for-more-efficiency-and-fun/</link>
		<comments>http://www.web-development-blog.com/archives/facebook-tips-for-more-efficiency-and-fun/#comments</comments>
		<pubDate>Mon, 09 Aug 2010 10:54:12 +0000</pubDate>
		<dc:creator>Olaf</dc:creator>
				<category><![CDATA[Google services]]></category>
		<category><![CDATA[Social Media]]></category>
		<category><![CDATA[facebook]]></category>
		<category><![CDATA[google]]></category>
		<category><![CDATA[like]]></category>
		<category><![CDATA[rss]]></category>
		<category><![CDATA[share]]></category>
		<category><![CDATA[social media]]></category>
		<category><![CDATA[youtube]]></category>

		<guid isPermaLink="false">http://www.web-development-blog.com/?p=1205</guid>
		<description><![CDATA[Since there are more than 500 million users at Facebook, that social network is the place to be meet most your friends. The last years the whole Internet is becoming more social and most new or existing services are providing social features which connect them to social sites like Facebook or Twitter. This article is [...]]]></description>
			<content:encoded><![CDATA[<p>Since there are more than 500 million users at Facebook, that social network is the place to be meet most your friends. The last years the whole Internet is becoming more social and most new or existing services are providing social features which connect them to social sites like Facebook or Twitter. This article is about how-to use Facebook more efficient together with some other services. We don&#8217;t show how-to abuse Facebook. Instead of showing how-to get lots of traffic we are using some tools which let you create more interesting content for your Facebook friends. </p>
<h2>Social features provided by Google</h2>
<p>Right these days there is an active discussion on how the Facebook &#8220;Like&#8221; function is able to manipulate the social rankings in Google. We think social media and Google Search are both important. Sure there are good social media features provided by Google, but they are not widely used. In this article we will explain how Google Reader, Google Sidewiki and YouTube can be used together with Facebook.</p>
<p><a href="http://www.web-development-blog.com/wp-content/uploads/2010/08/facebook_logo.png" rel="shadowbox[post-1205];player=img;"><img src="http://www.web-development-blog.com/wp-content/uploads/2010/08/facebook_logo-150x150.png" alt="" title="facebook_logo" width="150" height="150" class="alignright size-thumbnail wp-image-1224" /></a></p>
<h2>Your (Facebook) friends</h2>
<blockquote><p>Social media is based on having friends, without friends it&#8217;s not possible to interact and without interaction there is no fun. If you don&#8217;t like this, social media is not for you!</p></blockquote>
<p>While Facebook is a network for all your friends (you know), it should be the place where you meet people with similar interests. Invite people (you didn&#8217;t know in person) based on their interests. For example if most of your discussions on Facebook are about Internet marketing, invite people which are interested in similar subjects. Why? If you share marketing related stuff people which are not interested in, they getting bored and will discontinue your friendship. Most of us having friends on other networks as well and many of them should be your friend on Facebook as well. So if your friends are interested in your voice on Facebook, they might be interested what you&#8217;re saying on other networks as well (and visa verca).<span id="more-1205"></span></p>
<h2>Collect interesting content and share it to your friends</h2>
<p>Collecting content for your Facebook profile is easy, you can share interesting blogs from RSS feeds, websites you have discovered and YouTube videos you like. You can share every link from your browser using the Facebook &#8220;Share&#8221; tool (you can install a bookmarklet on your browser&#8217;s toolbar), but even if you&#8217;re logged in on Facebook you need to pass a CAPTCHA verification before your comment is posted.</p>
<h3>Share the best RSS feed items using the Google Reader</h3>
<p>Google Reader is a great tool to manage all your RSS subscriptions and for reading your feeds anywhere. This Google service is widely used by bloggers and you can subscribe to any RSS feed or just follow other Google Reader users if you like what they share. The tool provides a simple share button which will add your <a href="http://www.google.com/reader/shared/olaf.lederer" rel="nofollow">shared items</a> on your own RSS feed/list. In the web version it&#8217;s also a great idea to pass a comment by your shared items. The feature is available in the mobile version too, but there it&#8217;s a buggy function (at least on a windows mobile phone). There is a very good Facebook application called <a href="http://apps.facebook.com/rssgraffiti/" rel="nofollow">RSS Graffiti</a>, using this application, you can publish your <strong>Shared Items</strong> on Facebook just by importing the XML atom feed from Google Reader. The application has a lot of options for the way how you import your feeds (frequency, delay, filter, format, etc.).</p>
<p><img src="http://www.web-development-blog.com/wp-content/uploads/2010/08/rss-graffiti.png" alt="" title="rss-graffiti" width="522" height="334" class="alignnone size-full wp-image-1208" /></p>
<h3>Share your comments on YouTube on Facebook</h3>
<p>YouTube is the Video website on the net, Facebook can host videos too, but there is no search or discover functionality. Make sure you have a YouTube account and create also a <a href="http://www.youtube.com/finalwebsites">YouTube channel</a> where you met friends too. There is a great social feature available in Youtube that makes it possible to share all videos and comments on Facebook as well. Here are the settings (My Account -> Activity Sharing):</p>
<p><img src="http://www.web-development-blog.com/wp-content/uploads/2010/08/YouTube-Activity-Sharing-e1281261657974.png" alt="" title="YouTube - Activity Sharing" width="530" height="206" class="alignnone size-full wp-image-1209" /></p>
<p>On this screen you can choose which (YouTube) activities you like to share with your friends.</p>
<h3>Comment and share websites using Google Sidewiki</h3>
<p>Well the <a href="http://www.google.com/sidewiki/intl/en/index.html" rel="nofollow">Google Sidewiki</a> is not one of the famous service provided by Google, but there are some good points. All Google Sidewiki comments are published to your <a href="http://www.google.com/profiles/olaf.lederer#sidewiki" rel="nofollow">Google profile</a> and this page has also an RSS feed. You can use the RSS feed together with the RSS Graffiti application to share your website comments with your friends.</p>
<p><img src="http://www.web-development-blog.com/wp-content/uploads/2010/08/sidewiki-e1281261740696.png" alt="" title="sidewiki" width="530" height="385" class="alignnone size-full wp-image-1210" /></p>
<p>While using these Google services you&#8217;re able to share links, comments and videos with both friend groups and you will save time as well. I read the most of my RSS feeds on my mobile phone and using Google Reader I&#8217;m able to &#8220;post&#8221; items to my Facebook profile. If needed I can read those article next I&#8217;m behind my notebook and my friends on Facebook can read them too.</p>
<h2>Facebook for your blog or website</h2>
<p>Adding the Facebook &#8220;Share&#8221; button to your website is very easy, but people need to identity first (to block SPAM). With all the discussions about the Facebook &#8220;Like&#8221; function these days, it seems like that Facebook doesn&#8217;t &#8220;like&#8221; the share tool very much. Using the &#8221;Like&#8221; button, a Facebook user is able to share the link and is able to post a comment without leaving the page (check the &#8220;Like&#8221; feature on this page). To get this for 100% working you need to use XFBML version of this feature. We used the following instructions to get it working: </p>
<p>First create a new application on Facebook, access this <a href="http://developers.facebook.com/setup/" rel="nofollow">page</a> and enter the site name and URL. After this step is finished you should get a screen like this one:</p>
<p><img src="http://www.web-development-blog.com/wp-content/uploads/2010/08/facebook-app-e1281261833932.png" alt="" title="facebook-app" width="530" height="532" class="alignnone size-full wp-image-1211" /></p>
<h3>Integrate the Like-Gadget in your <a href="http://www.widgetready.org/buy-wordpress-themes.php">WordPress theme</a></h3>
<p>With the following information you&#8217;re able to prepare your website, we&#8217;re using WordPress for our example. Open your header.php template and replace your HTML opening tag with:</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">html</span> xmlns<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://www.w3.org/1999/xhtml&quot;</span></span>
<span style="color: #009900;">xmlns:og<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://opengraphprotocol.org/schema/&quot;</span></span>
<span style="color: #009900;">xmlns:fb<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://www.facebook.com/2008/fbml&quot;</span> &lt;?php language_attributes<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span>; ?&gt;</span>&gt;</pre></div></div>

<p>Now we need to add some meta information; The Facebook user ID is from your Facebook account. You can find that ID if you click your picture on your Facebook profile page. Copy/paste the application ID from the page where you created the application before. The image URL; You can use one standard image (logo) for all posts or use the thumbnails you&#8217;ve created for your blog posts (if you have done this). This is is how the image value should work, at the moment that this article is written it works random (Facebook is choosing an image from the page).</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">meta</span> property<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;fb:admins&quot;</span> <span style="color: #000066;">content</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;FACEBOOKUSERID&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">meta</span> property<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;fb:app_id&quot;</span> <span style="color: #000066;">content</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;YOUAPPLICATIONID&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span>
<span style="color: #009900;">&lt;?php if <span style="color: #66cc66;">&#40;</span>is_single<span style="color: #66cc66;">&#40;</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">&#41;</span> <span style="color: #66cc66;">&#123;</span> ?&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">meta</span> property<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;og:title&quot;</span> <span style="color: #000066;">content</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;&lt;?php single_post_title(); ?&gt;</span></span>&quot; /&gt;
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">meta</span> property<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;og:type&quot;</span> <span style="color: #000066;">content</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;article&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">meta</span> property<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;og:image&quot;</span> <span style="color: #000066;">content</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;IMAGEURL&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">meta</span> property<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;og:url&quot;</span> <span style="color: #000066;">content</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;&lt;?php the_permalink(); ?&gt;</span></span>&quot; /&gt;
<span style="color: #009900;">&lt;?php <span style="color: #66cc66;">&#125;</span> ?&gt;</span></pre></div></div>

<p>The snippet above prepares the template to use a &#8220;Like&#8221; button on single post page. Now we need to open the footer.php template file and next add the code before the BODY closing tag:</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;fb-root&quot;</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span>&gt;</span>
window.fbAsyncInit = function() {
	FB.init({
		appId: &quot;YOUAPPLICATIONID&quot;, status: true, cookie: true,
		xfbml: true
	});
};
(function() {
	var e = document.createElement('script'); e.async = true;
	e.src = document.location.protocol + '//connect.facebook.net/en_US/all.js';
	document.getElementById('fb-root').appendChild(e);
}());
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span></pre></div></div>

<p>Don&#8217;t forget to add your application ID here as well. Now we are ready to add the &#8220;Like&#8221; button to your single.php template file.</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;fb_like&quot;</span> <span style="color: #000066;">style</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;padding-bottom:5px;&quot;</span>&gt;</span>
	<span style="color: #009900;">&lt;fb:like <span style="color: #000066;">action</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">'like'</span> <span style="color: #000066;">width</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;400&quot;</span> layout<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;standard&quot;</span> show_faces<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;false&quot;</span> colorscheme<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;light&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span></pre></div></div>

<p>I placed that code above the part where the WordPress function the_content() is used.</p>
<h2>Conclusion</h2>
<p>In this article we talked about how-to discover and share content to your friends, but don&#8217;t forget that too much content might be recognized by your friends as SPAM. Find the right balance, if you keep adding friends and you friend-count doesn&#8217;t go up, maybe the frequency for posting external content (links) is too high. The social media user like to interact, give your friends content they can talk about and don&#8217;t forget to talk back!<br />
Adding Facebook gadgets to your website or blog can give your content new exposure and friends (fans). Just use them and if you think that they doesn&#8217;t work for you, it might be possible that your visitors are not on Facebook.<strong>Similar Posts:</strong>
<ul class="similar-posts">
<li><a href="http://www.web-development-blog.com/archives/social-media-services-are-more-efficient-these-days/" rel="bookmark" title="September 27, 2009">Social media services are more efficient these days</a></li>
<li><a href="http://www.web-development-blog.com/archives/google-wave-invitations-and-youtube-gadget/" rel="bookmark" title="November 15, 2009">Google Wave &#8211; Invitations and YouTube Gadget</a></li>
<li><a href="http://www.web-development-blog.com/archives/internet-marketing-strategies-and-blended-search/" rel="bookmark" title="October 24, 2007">Blended search and the importance of varying your website&#8217;s marketing methods</a></li>
</ul>
<p><!-- Similar Posts took 3.372 ms --></p>
]]></content:encoded>
			<wfw:commentRss>http://www.web-development-blog.com/archives/facebook-tips-for-more-efficiency-and-fun/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
		<item>
		<title>404 Errors: Report, monetize and analyse</title>
		<link>http://www.web-development-blog.com/archives/404-errors-report-monetize-and-analyse/</link>
		<comments>http://www.web-development-blog.com/archives/404-errors-report-monetize-and-analyse/#comments</comments>
		<pubDate>Mon, 14 Jun 2010 04:57:00 +0000</pubDate>
		<dc:creator>Olaf</dc:creator>
				<category><![CDATA[Google services]]></category>
		<category><![CDATA[PHP scripts]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[404 error]]></category>
		<category><![CDATA[adsense]]></category>
		<category><![CDATA[filter]]></category>
		<category><![CDATA[google]]></category>
		<category><![CDATA[google analytics]]></category>
		<category><![CDATA[site search]]></category>

		<guid isPermaLink="false">http://www.web-development-blog.com/?p=1136</guid>
		<description><![CDATA[After your websites getting more pages and links, the chance that a visitor will follow a dead link to your site exists. If a visitor is trying to access a page on your site, the server will report (normally) a 404 error. The response is by default some unfriendly page with some spare information about [...]]]></description>
			<content:encoded><![CDATA[<p>After your websites getting more pages and links, the chance that a visitor will follow a dead link to your site exists. If a visitor is trying to access a page on your site, the server will report (normally) a 404 error. The response is by default some unfriendly page with some spare information about the error which let most visitors stop visiting your site. But using the 404 error the right way, you the site owner can collect important information like:</p>
<ul>
<li>Of course the broken link or URL</li>
<li>The HTTP_REFERER information where the dead link is available</li>
<li>How often people try to access the bad URL</li>
</ul>
<p>Using the right tools you&#8217;re able to turn 404 errors into a powerful resource:</p>
<ul>
<li>Provide a site search feature and let people search what they are looking</li>
<li>Add advertisements to your error page and start earning money</li>
<li>Learn about what people like to see on your site</li>
</ul>
<p>In this tutorial we will show you how-to:</p>
<ul>
<li>Create a dynamic error page using the Google Site search and Adsense content ads</li>
<li>Setup Google analytics to track 404 errors using a filter</li>
<li>Set the site search feature with Google Analytics to collect the search queries from your visitor</li>
</ul>
<p><span id="more-1136"></span></p>
<h3>Error reporting page</h3>
<p>With the Apache webserver it&#8217;s possible to use custom directives for your error script, place this code into your .htaccess file (place the file into the site root):<br />
<code><br />
ErrorDocument 400 /error.php?err=400<br />
ErrorDocument 401 /error.php?err=401<br />
ErrorDocument 403 /error.php?err=403<br />
ErrorDocument 404 /error.php?err=404<br />
ErrorDocument 500 /error.php?err=500<br />
</code><br />
We use for the custom error script the most common HTTP errors.<br />
Next we need to create a PHP script called error.php which can handle the different errors:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #000088;">$errorNum</span> <span style="color: #339933;">=</span> <span style="color: #009900;">&#40;</span>int<span style="color: #009900;">&#41;</span><span style="color: #000088;">$_GET</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'err'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$err_str</span> <span style="color: #339933;">=</span> <span style="color: #990000;">array</span><span style="color: #009900;">&#40;</span><span style="color: #cc66cc;">404</span><span style="color: #339933;">=&gt;</span><span style="color: #0000ff;">'Not Found'</span><span style="color: #339933;">,</span> <span style="color: #cc66cc;">400</span><span style="color: #339933;">=&gt;</span><span style="color: #0000ff;">'Bad Request'</span><span style="color: #339933;">,</span> <span style="color: #cc66cc;">401</span><span style="color: #339933;">=&gt;</span><span style="color: #0000ff;">'Unauthorized'</span><span style="color: #339933;">,</span> <span style="color: #cc66cc;">403</span><span style="color: #339933;">=&gt;</span><span style="color: #0000ff;">'Forbidden'</span><span style="color: #339933;">,</span> <span style="color: #cc66cc;">500</span><span style="color: #339933;">=&gt;</span><span style="color: #0000ff;">'Internal Server Error'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'
&lt;html&gt;
&lt;head&gt;
&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=utf-8&quot; /&gt;
&lt;title&gt;'</span><span style="color: #339933;">.</span><span style="color: #000088;">$err_str</span><span style="color: #009900;">&#91;</span><span style="color: #000088;">$errorNum</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">'&lt;/title&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;h1&gt;An error occured: '</span><span style="color: #339933;">.</span><span style="color: #000088;">$err_str</span><span style="color: #009900;">&#91;</span><span style="color: #000088;">$errorNum</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">'&lt;/h1&gt;
&nbsp;
&lt;!-- place here your advertisement --&gt;
&nbsp;
&lt;!-- place here your Google analytics code --&gt;
&lt;/body&gt;
&lt;/html&gt;'</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>This script will show the different errors and also some advertisement if you add the ad code. Don&#8217;t forget to add the GA code snippet.</p>
<h3>Track dead links in Google Analytics</h3>
<p>In case of a 404 error the page title on this custom error page will be &#8220;Not Found&#8221;. We use the page title as a filter in Google Analytics to track the page views. Create a new profile for the site you&#8217;re working on and add this filter:</p>
<p><a href="http://www.web-development-blog.com/wp-content/uploads/2010/06/Edit-Filter-Google-Analytics1.png" rel="shadowbox[post-1136];player=img;"><img src="http://www.web-development-blog.com/wp-content/uploads/2010/06/Edit-Filter-Google-Analytics1-300x178.png" alt="" title="Edit-Filter-Google-Analytics" width="300" height="178" class="alignnone size-medium wp-image-1144" /></a></p>
<h3>Adding Google Site Search to your 404 error page</h3>
<p>If you haven&#8217;t done yet, create a <a href="http://www.google.com/cse/manage/create">Google site search</a> for your website. Add only your own website to the list of searched sites and don&#8217;t search the entire web. Add your Google Adsense ID (section &#8220;Make Money&#8221;) and head to the section &#8220;Look and feel&#8221; and select the option Iframe. Choose a style for the search form / result and maybe you like to customize the style. Push now the button &#8220;Get code&#8221; (or enter the section &#8220;Get code&#8221; from the sidebar) and enter there the URL from your error page.<br />
Copy / paste the code for the search form and the results into the body section from your error page. Your completed page will look like:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #000088;">$errorNum</span> <span style="color: #339933;">=</span> <span style="color: #009900;">&#40;</span>int<span style="color: #009900;">&#41;</span><span style="color: #000088;">$_GET</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'err'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$err_str</span> <span style="color: #339933;">=</span> <span style="color: #990000;">array</span><span style="color: #009900;">&#40;</span><span style="color: #cc66cc;">404</span><span style="color: #339933;">=&gt;</span><span style="color: #0000ff;">'Not Found'</span><span style="color: #339933;">,</span> <span style="color: #cc66cc;">400</span><span style="color: #339933;">=&gt;</span><span style="color: #0000ff;">'Bad Request'</span><span style="color: #339933;">,</span> <span style="color: #cc66cc;">401</span><span style="color: #339933;">=&gt;</span><span style="color: #0000ff;">'Unauthorized'</span><span style="color: #339933;">,</span> <span style="color: #cc66cc;">403</span><span style="color: #339933;">=&gt;</span><span style="color: #0000ff;">'Forbidden'</span><span style="color: #339933;">,</span> <span style="color: #cc66cc;">500</span><span style="color: #339933;">=&gt;</span><span style="color: #0000ff;">'Internal Server Error'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'
&lt;html&gt;
&lt;head&gt;
&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=utf-8&quot; /&gt;
&lt;title&gt;'</span><span style="color: #339933;">.</span><span style="color: #000088;">$err_str</span><span style="color: #009900;">&#91;</span><span style="color: #000088;">$errorNum</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">'&lt;/title&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;h1&gt;An error occured: '</span><span style="color: #339933;">.</span><span style="color: #000088;">$err_str</span><span style="color: #009900;">&#91;</span><span style="color: #000088;">$errorNum</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">'&lt;/h1&gt;
&nbsp;
&lt;form action=&quot;http://www.yourdomain.com/error.php&quot; id=&quot;cse-search-box&quot;&gt;
  &lt;div&gt;
    &lt;input type=&quot;hidden&quot; name=&quot;cx&quot; value=&quot;thisCodeIsProvidedByGoogleCSE&quot; /&gt;
    &lt;input type=&quot;hidden&quot; name=&quot;cof&quot; value=&quot;FORID:10&quot; /&gt;
    &lt;input type=&quot;hidden&quot; name=&quot;ie&quot; value=&quot;UTF-8&quot; /&gt;
    &lt;input type=&quot;text&quot; name=&quot;q&quot; size=&quot;31&quot; /&gt;
    &lt;input type=&quot;submit&quot; name=&quot;sa&quot; value=&quot;Zoeken&quot; /&gt;
  &lt;/div&gt;
&lt;/form&gt;
&lt;script type=&quot;text/javascript&quot; src=&quot;http://www.google.com/cse/brand?form=cse-search-box&amp;lang=en&quot;&gt;&lt;/script&gt;
&nbsp;
&lt;div id=&quot;cse-search-results&quot;&gt;&lt;/div&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
  var googleSearchIframeName = &quot;cse-search-results&quot;;
  var googleSearchFormName = &quot;cse-search-box&quot;;
  var googleSearchFrameWidth = 600;
  var googleSearchDomain = &quot;www.google.com&quot;;
  var googleSearchPath = &quot;/cse&quot;;
&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot; src=&quot;http://www.google.com/afsonline/show_afs_search.js&quot;&gt;&lt;/script&gt;'</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #990000;">empty</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$_GET</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'q'</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> <span style="color: #666666; font-style: italic;">// show the ad only if there is no search</span>
	<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'
&lt;!-- place here your advertisement --&gt;'</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span> 
<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'
&lt;!-- place here your Google analytics code --&gt;
&lt;/body&gt;
&lt;/html&gt;'</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>We placed the add code also into some <strong>IF</strong> clause, because there should not be another Google Adsense advertisement beside the Google ads from the result page.</p>
<h3>Enable site search tracking in Google Analytics</h3>
<p>The code for the error page is complete and we move to the last step: Tracking the site search queries from the error page. To do this we need to go in Google Analytics to the profile we created for the error page and click <strong>Edit</strong> (twice), check the setting <strong>Do Track Site Search</strong>, enter a &#8220;q&#8221; as the &#8220;Query Parameter&#8221; and click <strong>Safe Changes</strong>.</p>
<p>This error page is very basic and you need add your sites <a href="http://www.all4yourwebsite.com/website_templates.php">web template</a> to make it complete. If you like this tutorial and you have used the code on your own site please share the URL to your new or updated error page. Even if you don&#8217;t like to use the code from this page, we advice to track the errors and also the site search queries from your visitors. If you have questions or comments please post them below.<br />
<strong>Similar Posts:</strong>
<ul class="similar-posts">
<li><a href="http://www.web-development-blog.com/archives/top-your-sales-with-google-commerce-search/" rel="bookmark" title="November 29, 2009">Top your sales with Google Commerce Search</a></li>
<li><a href="http://www.web-development-blog.com/archives/new-search-options-but-unrelated-results-in-google-blog-search/" rel="bookmark" title="October 1, 2009">New Search Options but unrelated results in Google Blog Search</a></li>
<li><a href="http://www.web-development-blog.com/archives/create-custom-backups-from-your-website-using-curl/" rel="bookmark" title="July 30, 2008">Create custom backups from your website using cURL</a></li>
</ul>
<p><!-- Similar Posts took 3.697 ms --></p>
]]></content:encoded>
			<wfw:commentRss>http://www.web-development-blog.com/archives/404-errors-report-monetize-and-analyse/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>Sync Outlook and Google Apps on your mobile phone</title>
		<link>http://www.web-development-blog.com/archives/sync-outlook-and-google-apps-on-your-mobile-phone/</link>
		<comments>http://www.web-development-blog.com/archives/sync-outlook-and-google-apps-on-your-mobile-phone/#comments</comments>
		<pubDate>Thu, 13 May 2010 12:29:24 +0000</pubDate>
		<dc:creator>Olaf</dc:creator>
				<category><![CDATA[Google services]]></category>
		<category><![CDATA[activesync]]></category>
		<category><![CDATA[calendar]]></category>
		<category><![CDATA[google apps]]></category>
		<category><![CDATA[outlook]]></category>
		<category><![CDATA[synchronize]]></category>
		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://www.web-development-blog.com/?p=1084</guid>
		<description><![CDATA[I&#8217;m using Google Apps as my primary e-mail service for almost 4 years now and I must say the product has grown a lot within the last 2 years. A year ago I got my first cell phone powered by windows mobile and a few days ago I decided to synchronize my e-mail plus calendar [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m using Google Apps as my primary e-mail service for almost 4 years now and I must say the product has grown a lot within the last 2 years. A year ago I got my first cell phone powered by windows mobile and a few days ago I decided to synchronize my e-mail plus calendar with the data I have entered on my phone. Just one more feature offered by Google Apps.</p>
<p>Honestly I tried this before but without success, why? Because I missed one big point, this service is only available for <strong>premium accounts</strong>. In my case, I like to synchronize much more. As I mentioned before, I have a &#8220;personal&#8221; Google Apps account and a Windows mobile phone, but I&#8217;m using also a Microsoft Exchange account at the office, which I like to synchronize with my Windows mobile phone. The synchronization tool on the phone allows only one server and in fact I have two. But there is a possibility to arrange this.</p>
<h3>Synchronize Microsoft Outlook with Google Apps</h3>
<p>There is a <a href="https://tools.google.com/dlpage/gappssync" rel="nofollow">Google Apps Sync tool</a> to synchronize both accounts (Outlook and Google Apps) with each other including contacts, e-mail, tasks and the calendar. I tried that tool, but I don&#8217;t like to have a second Outlook profile for my personal stuff. 1-2 year ago there was already the <a href="http://www.google.com/support/calendar/bin/answer.py?answer=89955" rel="nofollow">Google Calendar Sync tool</a> which is able to synchronize the Outlook calendar with the calendar from a Google Apps account. I needed to search the Google Calendar Documentation to find this tool back because Google doesn&#8217;t mention this tool anymore (the suggest the new sync tool instead). It works for Outlook 2003/2007 and with the latest version I&#8217;m able to synchronize my calendars in one or two ways:<span id="more-1084"></span></p>
<p><a href="http://www.web-development-blog.com/wp-content/uploads/2010/05/calendar-sync-tool.jpg" rel="shadowbox[post-1084];player=img;"><img src="http://www.web-development-blog.com/wp-content/uploads/2010/05/calendar-sync-tool-285x300.jpg" alt="" title="google calendar sync tool" width="285" height="300" class="alignnone size-medium wp-image-1088" /></a></p>
<p>In my case I want to show events from my Outlook calendar in my Google calendar; this is the one way synchronization (the 3rd option). I&#8217;m very surprised about the quality of this tool. I tested the following calendar updates, I made in Microsoft Outlook and all of them are updated to my Google calendar as well:</p>
<ul>
<li>Changing details from an existing item in the future</li>
<li>Moving the item to another day</li>
<li>Removing the item from the calendar</li>
<li>Updating some items from the past</li>
</ul>
<p>After the synchronization between Outlook and Google Apps is working we can start the synchronization between Google Apps and my Windows phone.</p>
<h3>Synchronize Google Apps with Windows Mobile</h3>
<p>Be sure you have a Google Apps <strong>Premium account</strong> and ActiveSync is available on your Windows mobile phone. Otherwise the synchronization will not work. Follow the instructions on how-to setup the Google Apps account for ActiveSync using these <a href="http://www.google.com/support/mobile/bin/answer.py?answer=138636&#038;topic=14299" rel="nofollow">instructions</a>. The screen-shots on that page might be different from them on your phone, but they should explain how-to setup the different options. I suggest to un-check the <strong>Contacts</strong>; in my case I use 20-30 contacts on my phone and have hundreds in my contact list on Google (you don&#8217;t wanna sync them all). After anything is done start the synchronization, but don&#8217;t forget that the synchronization process is done via the mobile Internet. If you don&#8217;t have a mobile Internet account it might be very expensive for you.</p>
<p><strong>Similar Posts:</strong>
<ul class="similar-posts">
<li><a href="http://www.web-development-blog.com/archives/online-backup-service-comparison/" rel="bookmark" title="June 5, 2010">Online Backup Service &#8211; Comparison</a></li>
<li><a href="http://www.web-development-blog.com/archives/facebook-tips-for-more-efficiency-and-fun/" rel="bookmark" title="August 9, 2010">Facebook tips for more efficiency and &#8220;fun&#8221;</a></li>
<li><a href="http://www.web-development-blog.com/archives/create-surveys-with-google-forms/" rel="bookmark" title="April 6, 2010">Create surveys with Google Forms</a></li>
</ul>
<p><!-- Similar Posts took 3.608 ms --></p>
]]></content:encoded>
			<wfw:commentRss>http://www.web-development-blog.com/archives/sync-outlook-and-google-apps-on-your-mobile-phone/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Create surveys with Google Forms</title>
		<link>http://www.web-development-blog.com/archives/create-surveys-with-google-forms/</link>
		<comments>http://www.web-development-blog.com/archives/create-surveys-with-google-forms/#comments</comments>
		<pubDate>Tue, 06 Apr 2010 08:52:41 +0000</pubDate>
		<dc:creator>Olaf</dc:creator>
				<category><![CDATA[Google services]]></category>
		<category><![CDATA[Reviews]]></category>
		<category><![CDATA[documents]]></category>
		<category><![CDATA[forms]]></category>
		<category><![CDATA[google]]></category>
		<category><![CDATA[google apps]]></category>
		<category><![CDATA[spreadsheet]]></category>
		<category><![CDATA[surveys]]></category>

		<guid isPermaLink="false">http://www.web-development-blog.com/?p=1014</guid>
		<description><![CDATA[These days I needed an online tool to create a customer survey. Google Docs has a form feature which I tried this time and I was very surprised how easy and powerful this function is. Using Google forms, you don&#8217;t need any knowledge about how a web based form works. In this article we will [...]]]></description>
			<content:encoded><![CDATA[<p>These days I needed an online tool to create a customer survey. Google Docs has a form feature which I tried this time and I was very surprised how easy and powerful this function is. Using Google forms, you don&#8217;t need any knowledge about how a web based form works. In this article we will show-case the following functionality:</p>
<ul>
<li>Create a form with the WYSIWYG form editor</li>
<li>How your customers getting access to the survey</li>
<li>Analyze and and work on the results</li>
<li><strong>Optional:</strong> How-to insert your survey form in your website using a lightbox</li>
</ul>
<h3>About Google Forms and Google Docs</h3>
<p>Google Forms is part of Google Docs or better some kind of extension for Google Spreadsheets a web based spreadsheet program. To create a form using Google Docs, you need to have a Google account or a <a href="http://www.google.com/apps/intl/en/business/index.html" rel="nofollow">Google Apps</a> account. Both account types are free available. Google offers also premium services for Google applications.<br />
<span id="more-1014"></span></p>
<h3>Creating web based forms without being a webmaster</h3>
<p>If you start using Google Docs the first time, you get the idea that you&#8217;re using a similar application from the Microsoft Office suite. The menu and a lot of functions are very similar. Creating a form is very easy, you don&#8217;t need to write any code, just click some buttons and enter your text information:</p>

<a href='http://www.web-development-blog.com/wp-content/uploads/2010/04/summary.png' rel='shadowbox[album-1014];player=img;' title='Summary'><img width="150" height="150" src="http://www.web-development-blog.com/wp-content/uploads/2010/04/summary-150x150.png" class="attachment-thumbnail" alt="Summary" title="Summary" /></a>
<a href='http://www.web-development-blog.com/wp-content/uploads/2010/04/resulttable.png' rel='shadowbox[album-1014];player=img;' title='Results'><img width="150" height="150" src="http://www.web-development-blog.com/wp-content/uploads/2010/04/resulttable-150x150.png" class="attachment-thumbnail" alt="Results" title="Results" /></a>
<a href='http://www.web-development-blog.com/wp-content/uploads/2010/04/conformation.png' rel='shadowbox[album-1014];player=img;' title='Confirmation Screen'><img width="150" height="150" src="http://www.web-development-blog.com/wp-content/uploads/2010/04/conformation-150x150.png" class="attachment-thumbnail" alt="Confirmation Screen" title="Confirmation Screen" /></a>
<a href='http://www.web-development-blog.com/wp-content/uploads/2010/04/editform.png' rel='shadowbox[album-1014];player=img;' title='Edit form'><img width="150" height="150" src="http://www.web-development-blog.com/wp-content/uploads/2010/04/editform-150x150.png" class="attachment-thumbnail" alt="Edit form" title="Edit form" /></a>
<a href='http://www.web-development-blog.com/wp-content/uploads/2010/04/datatypes.png' rel='shadowbox[album-1014];player=img;' title='Form elements'><img width="150" height="150" src="http://www.web-development-blog.com/wp-content/uploads/2010/04/datatypes-150x150.png" class="attachment-thumbnail" alt="Form elements" title="Form elements" /></a>
<a href='http://www.web-development-blog.com/wp-content/uploads/2010/04/themes.png' rel='shadowbox[album-1014];player=img;' title='Themes for Google Forms'><img width="150" height="150" src="http://www.web-development-blog.com/wp-content/uploads/2010/04/themes-150x150.png" class="attachment-thumbnail" alt="Themes for Google Forms" title="Themes for Google Forms" /></a>

<p>Using Google Docs, you can build forms with all form elements you need: text fields, text areas, check boxes, radio buttons, select lists. Create forms with multiple pages and describe each page and/or form element with the information you like. There are also basic validations for required fields.<br />
Every element has clear and easy to use dialogs. Based on the language you&#8217;re using in Google Docs, you can create forms in most common languages. If your form is ready, you can choose from many fancy themes or if you don&#8217;t like them use plain theme type.</p>
<h3>How-to send the survey to your customers?</h3>
<p>Each Google Form is connected to the contact list from your Gmail account, you can use this list or just post the link to your survey using your <a href="http://www.web-development-blog.com/archives/integrate-your-mailchimp-newsletter-subscription/">mailing list hosted by Mailchimp</a> or any other provider you like. If you use the Google contact list you should create a contact group to save time.  Google Apps users are able to collect the user name and/or restrict the form only for users having an Google account from the same domain. If you use a regular Google account, these functions are not available. Don&#8217;t forget to post the survey to your company&#8217;s facebook fan page or your twitter feed if you have one or both of them.</p>
<h3>Easy data access and statistics</h3>
<p>Every form submission is stored in a spreadsheet at the moment the user has clicked the submit button. All submitted form values are accessible and stored together with the timestamp from the moment that the form was submitted. Beside the spreadsheet there is a data summary using graphics which will give you some quick information about how often the data was submitted. </p>
<h3>Optional: Stylish integrations for your website or blog</h3>
<p>Since Google Forms are hosted off-site, you need  some way to embed the code in your website. Google is offering some code snippet which you can use as an Iframe but you can&#8217;t customize the style to match your own site&#8217;s design. Because you can&#8217;t change the style or code, we need an easy way &#8220;make it a part&#8221; from your website:</p>
<ol>
<li>Create your form and use the plain theme</li>
<li>Add the following code to your websites header to include jQuery and the thickbox plugin:

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;jquery.js&quot;</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;thickbox.js&quot;</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">link</span> <span style="color: #000066;">rel</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;stylesheet&quot;</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/css&quot;</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;thickbox.css&quot;</span> <span style="color: #000066;">media</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;screen&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span></pre></div></div>

<p>You need to download upload the files if they don&#8217;t exist on your site.
</li>
<li>Create a link to the form URL (copy paste from the footer section on the page where you can edit the form)

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://spreadsheets.google.com/viewform?hl=en&amp;formkey=dDZjNGROdVllS2JYMGdSZnVSSWF4YkE6MA&amp;TB_iframe=true&amp;height=400&amp;width=500&quot;</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;thickbox&quot;</span>&gt;</span>Survey Form<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;</span></pre></div></div>

<p>Don&#8217;t mix the query parameters, any parameter after &#8220;TB_iframe&#8221; is not recognized on the target page. Change also the values for the width and height to match your forms dimensions. The pseudo class name &#8220;thickbox&#8221; is used to enable the tickbox feature.
</li>
<li>After submission Google will show a confirmation screen, don&#8217;t forget to edit this message (from the edit screen: More actions -> Edit confirmation</li>
</ol>
<p>We created some <a href="http://spreadsheets.google.com/viewform?formkey=dDZjNGROdVllS2JYMGdSZnVSSWF4YkE6MA" rel="shadowbox;height=480;width=640" title="Google Forms example">example forms</a> using multiple pages and most of the form elements. </p>
<p><strong>Similar Posts:</strong>
<ul class="similar-posts">
<li><a href="http://www.web-development-blog.com/archives/integrate-your-mailchimp-newsletter-subscription/" rel="bookmark" title="October 26, 2009">Integrate your MailChimp Newsletter Subscription</a></li>
<li><a href="http://www.web-development-blog.com/archives/jquery-form-plugin-and-php-file-uploads/" rel="bookmark" title="November 2, 2009">jQuery form plugin and PHP file uploads</a></li>
<li><a href="http://www.web-development-blog.com/archives/jquery-contact-form-for-your-website/" rel="bookmark" title="January 11, 2010">jQuery Contact form for your website</a></li>
</ul>
<p><!-- Similar Posts took 3.935 ms --></p>
]]></content:encoded>
			<wfw:commentRss>http://www.web-development-blog.com/archives/create-surveys-with-google-forms/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Google Custom Search in a Lightbox!</title>
		<link>http://www.web-development-blog.com/archives/google-custom-search-in-a-lightbox/</link>
		<comments>http://www.web-development-blog.com/archives/google-custom-search-in-a-lightbox/#comments</comments>
		<pubDate>Fri, 05 Feb 2010 08:42:33 +0000</pubDate>
		<dc:creator>Olaf</dc:creator>
				<category><![CDATA[Google services]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[jQuery Code]]></category>
		<category><![CDATA[api]]></category>
		<category><![CDATA[google]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[search]]></category>
		<category><![CDATA[thickbox]]></category>

		<guid isPermaLink="false">http://www.web-development-blog.com/?p=869</guid>
		<description><![CDATA[There are several tutorials on the Internet on how-to integrate the Google Custom search in your website, but the results are not very attractive. The older iframe version doesn&#8217;t fit perfectly in most of our templates and the style for ads and results doesn&#8217;t look good in the past. A few month Google has released [...]]]></description>
			<content:encoded><![CDATA[<p>There are several tutorials on the Internet on how-to integrate the Google Custom search in your website, but the results are not very attractive. The older iframe version doesn&#8217;t fit perfectly in most of our templates and the style for ads and results doesn&#8217;t look good in the past. A few month Google has released some nice new features:</p>
<ul>
<li>Custom search element placements</li>
<li>Custom styles and themes using CSS</li>
<li>Promotions, set your own premium results for specific search queries</li>
<li>A new AJAX powered CSE using the Google AJAX API loader</li>
</ul>
<p><a href="http://www.web-development-blog.com/wp-content/uploads/2010/02/Google-Custom-Search.png" rel="shadowbox[post-869];player=img;"><img src="http://www.web-development-blog.com/wp-content/uploads/2010/02/Google-Custom-Search-300x156.png" alt="" title="Google-Custom-Search" width="300" height="156" class="alignnone size-medium wp-image-874" /></a></p>
<p>With all these new features the CSE (Custom Search Engine) becomes very attractive to use it on your own site as site search. In this tutorial we show you how-to add the custom search feature to you site using jQuery, the Thickbox plugin and the AJAX API provided by Google. To do this <strong>a result page is not necessary</strong> anymore, we show only a search box somewhere on a particular website.<span id="more-869"></span></p>
<h3>Including the Google API, jQuery and the Thickbox plugin</h3>
<p>First include the following rows to your page HEAD, you need to add them on every page where you like to show the search box.</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;jquery-1.3.2.min.js&quot;</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">link</span> <span style="color: #000066;">rel</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;stylesheet&quot;</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;thickbox.css&quot;</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/css&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;thickbox.js&quot;</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">script</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/javascript&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://www.google.com/jsapi?key=YOURAPYKEY&quot;</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">script</span>&gt;</span></pre></div></div>

<p>To use the Google API you need to register an API key for your website, request a key <a href="http://code.google.com/apis/ajaxsearch/signup.html" rel="nofollow">here</a>.</p>
<h3>HTML code for the search box</h3>
<p>Below the simple HTML code for the search form and the container for the results. Place both somewhere on your webpage.</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;searchcont&quot;</span>&gt;</span>
	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">label</span> <span style="color: #000066;">for</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;query_input&quot;</span>&gt;</span>Search Query: <span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">label</span>&gt;</span>
	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">input</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text&quot;</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;query_input&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span>
	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">input</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;button&quot;</span> <span style="color: #000066;">value</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;ok&quot;</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;searchbtn&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;resultcont&quot;</span>&gt;</span>
	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;title&quot;</span> <span style="color: #000066;">style</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;visibility:hidden;&quot;</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;#&quot;</span>&gt;</span>Close<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;results&quot;</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span></pre></div></div>

<h3>jQuery code snippet</h3>
<p>The following JS code will load the Google API and if the user has clicked the search button the <a href="http://code.google.com/apis/ajaxsearch/documentation/customsearch/index.html#_class_CSC" rel="nofollow">customSearchControl</a> is initiated, the Thickbox is called, the title inside the Thickbox becomes visible, the result element is prepared and at last the input element value is executed for the search query. Add this code in your page&#8217;s HEAD surrounded by some script tags.</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;">google.<span style="color: #660066;">load</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'search'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'1'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
$<span style="color: #009900;">&#40;</span>document<span style="color: #009900;">&#41;</span>.<span style="color: #660066;">ready</span><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;#searchbtn&quot;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">click</span><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span> <span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #003366; font-weight: bold;">var</span> customSearchControl <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">new</span> google.<span style="color: #660066;">search</span>.<span style="color: #660066;">CustomSearchControl</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'UNIQUE_CSE_ID'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		tb_show<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;&quot;</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">&quot;#TB_inline?height=480&amp;width=800&amp;inlineId=resultcont&amp;modal=true&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#title'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">css</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;visibility&quot;</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">&quot;visible&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>   
		<span style="color: #003366; font-weight: bold;">var</span> drawOptions <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">new</span> google.<span style="color: #660066;">search</span>.<span style="color: #660066;">DrawOptions</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		customSearchControl.<span style="color: #660066;">draw</span><span style="color: #009900;">&#40;</span>document.<span style="color: #660066;">getElementById</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;results&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span> drawOptions<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		customSearchControl.<span style="color: #660066;">execute</span><span style="color: #009900;">&#40;</span>document.<span style="color: #660066;">getElementById</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;query_input&quot;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">value</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;#title a&quot;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">click</span><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span> <span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		tb_remove<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#title'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">css</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;visibility&quot;</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">&quot;hidden&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>   
		$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;#results&quot;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">hide</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<p>The other click event is used to hide the Thickbox, the event will hide the title and hides also the results. The last action is needed because we show an inline element, if we don&#8217;t hide the content the results are still visible after the Thickbox is closed.</p>
<p>That&#8217;s all, simple or not? The code above needs of course some styling. I used a slightly modified version for my network site search on this blog. If you search for &#8220;wordpress&#8221; you see the &#8220;promotion&#8221; feature I mentioned above.</p>
<p><strong>Similar Posts:</strong>
<ul class="similar-posts">
<li><a href="http://www.web-development-blog.com/archives/ajax-requests-using-jquery-and-php/" rel="bookmark" title="December 24, 2009">Ajax requests using jQuery and PHP</a></li>
<li><a href="http://www.web-development-blog.com/archives/5-useful-jquery-snippets-for-your-website/" rel="bookmark" title="August 23, 2010">5 Useful jQuery Snippets for your Website</a></li>
<li><a href="http://www.web-development-blog.com/archives/your-e-mail-address-hidden-with-jquery/" rel="bookmark" title="February 25, 2010">Your e-mail address hidden with jQuery?</a></li>
</ul>
<p><!-- Similar Posts took 3.689 ms --></p>
]]></content:encoded>
			<wfw:commentRss>http://www.web-development-blog.com/archives/google-custom-search-in-a-lightbox/feed/</wfw:commentRss>
		<slash:comments>18</slash:comments>
		</item>
		<item>
		<title>Add a Google Sitemap for your Posterous Blog</title>
		<link>http://www.web-development-blog.com/archives/add-a-google-sitemap-for-your-posterous-blog/</link>
		<comments>http://www.web-development-blog.com/archives/add-a-google-sitemap-for-your-posterous-blog/#comments</comments>
		<pubDate>Wed, 18 Nov 2009 19:53:30 +0000</pubDate>
		<dc:creator>finalwebsites.com</dc:creator>
				<category><![CDATA[Google services]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[google]]></category>
		<category><![CDATA[Posterous]]></category>
		<category><![CDATA[sitemaps]]></category>
		<category><![CDATA[themes]]></category>
		<category><![CDATA[webmaster tools]]></category>

		<guid isPermaLink="false">http://www.web-development-blog.com/?p=642</guid>
		<description><![CDATA[Posterous is a great hosted Blog system that we talked about in this blog about social media services. The current version has already a lot of features like custom themes and functions for services like Twitter and Facebook. The best of all their service is still free! I noticed the last weeks that Google doesn&#8217;t [...]]]></description>
			<content:encoded><![CDATA[<p>Posterous is a great hosted Blog system that we talked about in this blog about <a href="http://www.web-development-blog.com/archives/social-media-services-are-more-efficient-these-days/">social media services</a>. The current version has already a lot of features like custom themes and functions for services like Twitter and Facebook.</p>
<blockquote><p>The best of all their service is still free!</p></blockquote>
<p>I noticed the last weeks that Google doesn&#8217;t index all my Posterous pages and that while I point my blog <a href="http://primeblogger.com">Prime Blogger</a> to a .com domain name. My first idea was a missing Google Sitemap. I tried before to add my Posterous site to my Google Webmaster Tools account, but this requires a custom meta tag on your homepage or you need to upload a unique file to your site to proof the ownership. I suggested a function for a Google Sitemap to Brett from Posterous  and he gave me the hint that I&#8217;m able to change the HTML using a custom theme and yes this is key to get your site accepted in your Google Webmaster Tools account.</p>
<p>Just add your site to your account and choose the meta tag to proof the sites ownership:<span id="more-642"></span></p>
<p><a href="http://www.web-development-blog.com/wp-content/uploads/2009/11/verify-ownership.png" rel="shadowbox[post-642];player=img;"><img class="alignnone size-medium wp-image-643" title="verify ownership" src="http://www.web-development-blog.com/wp-content/uploads/2009/11/verify-ownership-300x203.png" alt="verify ownership" width="300" height="203" /></a></p>
<p>Next surf to your Posterous site and in the control panel choose your blog -&gt; Settings -&gt; Theme and customize my site -&gt; Advanced.</p>
<p>Paste the meta tag code into the code box at the top. Save the settings and confirm to copy your custom theme settings.</p>
<p><a href="http://www.web-development-blog.com/wp-content/uploads/2009/11/meta_posterous.jpg" rel="shadowbox[post-642];player=img;"><img class="alignnone size-medium wp-image-644" title="meta posterous" src="http://www.web-development-blog.com/wp-content/uploads/2009/11/meta_posterous-300x80.jpg" alt="meta posterous" width="300" height="80" /></a></p>
<p>Now it&#8217;s possible to confirm the website ownership within the Google Webmaster Tools. Next we like to add a sitemap, click Site Configuration -&gt; Sitemaps -&gt; Submit a sitemap</p>
<p>Posterous doesn&#8217;t offer a Google sitemap format but you can use the XML feed instead. This gives you not a complete sitemap but at least you can submit the latest 20 blogs to Google. I hope it helps&#8230;<strong>Similar Posts:</strong>
<ul class="similar-posts">
<li><a href="http://www.web-development-blog.com/archives/a-new-wordpress-theme-for-our-blog/" rel="bookmark" title="March 15, 2009">A new WordPress theme for our blog</a></li>
<li><a href="http://www.web-development-blog.com/archives/optimizing-your-wordpress-blog-for-google-part-2/" rel="bookmark" title="April 14, 2008">Optimizing your WordPress Blog for Google: Part 2</a></li>
<li><a href="http://www.web-development-blog.com/archives/social-media-services-are-more-efficient-these-days/" rel="bookmark" title="September 27, 2009">Social media services are more efficient these days</a></li>
</ul>
<p><!-- Similar Posts took 3.589 ms --></p>
]]></content:encoded>
			<wfw:commentRss>http://www.web-development-blog.com/archives/add-a-google-sitemap-for-your-posterous-blog/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Google Wave &#8211; Invitations and YouTube Gadget</title>
		<link>http://www.web-development-blog.com/archives/google-wave-invitations-and-youtube-gadget/</link>
		<comments>http://www.web-development-blog.com/archives/google-wave-invitations-and-youtube-gadget/#comments</comments>
		<pubDate>Sun, 15 Nov 2009 21:21:50 +0000</pubDate>
		<dc:creator>Olaf</dc:creator>
				<category><![CDATA[Google services]]></category>
		<category><![CDATA[Reviews]]></category>
		<category><![CDATA[gadgets]]></category>
		<category><![CDATA[generator]]></category>
		<category><![CDATA[google wave]]></category>
		<category><![CDATA[invitations]]></category>
		<category><![CDATA[youtube]]></category>

		<guid isPermaLink="false">http://www.web-development-blog.com/?p=628</guid>
		<description><![CDATA[Finally I&#8217;m in, I got my invitation for Google Wave! After creating the first Wave pages I can say that the system looks really cool and I&#8217;m very happy that it&#8217;s browser based and not some Windows desktop application. Why should I use Google Wave? First what people asked me after I told them about [...]]]></description>
			<content:encoded><![CDATA[<p><img class="size-full wp-image-630 alignleft" style="margin-left: 5px; margin-right: 5px;" title="google_wave_logo" src="http://www.web-development-blog.com/wp-content/uploads/2009/11/google_wave_logo.jpg" alt="google_wave_logo" width="120" height="120" />Finally I&#8217;m in, I got my invitation for Google Wave! After creating the first Wave pages I can say that the system looks really cool and I&#8217;m very happy that it&#8217;s browser based and not some Windows desktop application.</p>
<h3>Why should I use Google Wave?</h3>
<p>First what people asked me after I told them about Google Wave was: &#8220;Why should I use it and what is so special?&#8221; If the same people are already on Twitter and/or Facebook it&#8217;s easy to explain; It&#8217;s like Facebook, Twitter or MSN. Google Wave is a tool to share your content with other friends in real time and also private communication tool. Currently is Google Wave a preview release and I&#8217;m sure we will see much more features before the system is out of a future Beta period. I think a lot of people are missing the function to publish their content to others users without adding them to a conversation and you can&#8217;t discover stuff or profiles from others. On the other site there are already features like real time content updates and adding content is very easy and powerful. Adding content is like creating a word document with abilities to add images, links, gadgets and attachments.</p>
<h3>Gadgets are allowed but there is no function for YouTube videos</h3>
<p>As I said before, its possible to add gadgets to your Wave. <span id="more-628"></span>Add Google maps, simple polls and many gadgets from the google gadget gallery. Since Google Wave is in an early state, not every 3rd party gadget works and adding gadgets is limited. The first thing I noticed is that there is no standard function to add YouTube videos to your Wave. We (finalwebsites.com) created a small <strong><a href="http://www.finalwebsites.com/googlewave/">YouTube Gadget Generator</a></strong> to create your custom YouTube Video object. Using this generator it&#8217;s possible to create a gadget from every YouTube Video URL.</p>
<p><a href="http://www.web-development-blog.com/wp-content/uploads/2009/11/Wave_Youtube_Screenshot.jpg" rel="shadowbox[post-628];player=img;"><img class="alignnone size-medium wp-image-631" title="Wave_Youtube_Screenshot" src="http://www.web-development-blog.com/wp-content/uploads/2009/11/Wave_Youtube_Screenshot-300x145.jpg" alt="Wave_Youtube_Screenshot" width="300" height="145" /></a></p>
<h3>Google Wave Invitations available</h3>
<p>We like to share 10 Google Wave Invitations with our blog reader. If you like have one, post some nice comment why you deserve one of the invitations. We publish the most creative responses in the comment list below and we give away the invitations in a random order.</p>
<blockquote><p>Invitations for Google Wave are send via the interface from Google wave. There is no code or something we can send via email or this website. If you like to get invited, provide your e-mail address which is connected with a Google account or your Gmail address. Post this e-mail address with your comment and mark this address: &#8220;My Google account is &#8230;&#8221;</p></blockquote>
<p><strong>Similar Posts:</strong>
<ul class="similar-posts">
<li><a href="http://www.web-development-blog.com/archives/facebook-tips-for-more-efficiency-and-fun/" rel="bookmark" title="August 9, 2010">Facebook tips for more efficiency and &#8220;fun&#8221;</a></li>
<li><a href="http://www.web-development-blog.com/archives/just-a-better-internet-portal-provided-by-google/" rel="bookmark" title="October 19, 2008">Just a better Internet portal provided by Google</a></li>
<li><a href="http://www.web-development-blog.com/archives/your-favorite-google-gadgets-on-your-website/" rel="bookmark" title="October 5, 2006">Your favorite Google Gadgets on your website</a></li>
</ul>
<p><!-- Similar Posts took 3.605 ms --></p>
]]></content:encoded>
			<wfw:commentRss>http://www.web-development-blog.com/archives/google-wave-invitations-and-youtube-gadget/feed/</wfw:commentRss>
		<slash:comments>53</slash:comments>
		</item>
		<item>
		<title>New Search Options but unrelated results in Google Blog Search</title>
		<link>http://www.web-development-blog.com/archives/new-search-options-but-unrelated-results-in-google-blog-search/</link>
		<comments>http://www.web-development-blog.com/archives/new-search-options-but-unrelated-results-in-google-blog-search/#comments</comments>
		<pubDate>Thu, 01 Oct 2009 18:40:01 +0000</pubDate>
		<dc:creator>Olaf</dc:creator>
				<category><![CDATA[Google services]]></category>
		<category><![CDATA[Google, SEO]]></category>
		<category><![CDATA[blog search]]></category>
		<category><![CDATA[google]]></category>
		<category><![CDATA[search]]></category>
		<category><![CDATA[search options]]></category>

		<guid isPermaLink="false">http://www.web-development-blog.com/?p=496</guid>
		<description><![CDATA[Today I read about the new search options on this Google Blog and thought great more control. I didn&#8217;t understood why people should use the Blog Search feature from Google because I was never that satisfied as the regular search. Using the new search options I tried some searches and selected the Blog filter as [...]]]></description>
			<content:encoded><![CDATA[<p>Today I read about the new search options on this <a href="http://googleblog.blogspot.com/2009/10/refine-your-search-results-with-new.html" rel="nofollow">Google Blog</a> and thought great more control. I didn&#8217;t understood why people should use the Blog Search feature from Google because I was never that satisfied as the regular search. </p>
<p><a href="http://www.seobook.com/842-16-1-38.html" target="_blank" rel="nofollow"><img border="0" src="http://www.seobook.com/rf/banners/seobook-468x60-free.gif" width="468" height="60"></a></p>
<p>Using the new search options I tried some searches and selected the Blog filter as well. I was very surprised to find in the Blog search result a few duplicates from my <a href="http://www.web-development-blog.com/archives/upload-in-modal-window-and-pass-values-with-jquery/">Blog post</a> two weeks ago. </p>
<p><a href="http://www.web-development-blog.com/wp-content/uploads/2009/10/Upload-in-modal-window-Google-Search.png" rel="shadowbox[post-496];player=img;"><img src="http://www.web-development-blog.com/wp-content/uploads/2009/10/Upload-in-modal-window-Google-Search-300x191.png" alt="Upload in modal window - Google Blog Search" title="Upload in modal window - Google Blog Search" width="300" height="191" class="alignnone size-medium wp-image-497" /></a><span id="more-496"></span></p>
<p>First I thought maybe my blog was not so relevant at the moment, but after I switched off the Blog filter I found my Blog post at the top of the list. </p>
<p><a href="http://www.web-development-blog.com/wp-content/uploads/2009/10/Upload-in-modal-window-Google-Search2.png" rel="shadowbox[post-496];player=img;"><img src="http://www.web-development-blog.com/wp-content/uploads/2009/10/Upload-in-modal-window-Google-Search2-300x116.png" alt="Upload in modal window - Google Web Search" title="Upload in modal window - Google Web Search" width="300" height="116" class="alignnone size-medium wp-image-498" /></a></p>
<p>I know that the Blog search has some great real time results but this make no sense. Google shows some excepts or duplicates instead of the original content.  <strong>Similar Posts:</strong>
<ul class="similar-posts">
<li><a href="http://www.web-development-blog.com/archives/adsense-for-wordpress-5-plugins-reviewed/" rel="bookmark" title="November 30, 2009">Adsense for WordPress &#8211; 5 Plugins reviewed</a></li>
<li><a href="http://www.web-development-blog.com/archives/a-new-wordpress-theme-for-our-blog/" rel="bookmark" title="March 15, 2009">A new WordPress theme for our blog</a></li>
<li><a href="http://www.web-development-blog.com/archives/this-generation-web-advertising/" rel="bookmark" title="November 7, 2006">This generation web advertising</a></li>
</ul>
<p><!-- Similar Posts took 3.302 ms --></p>
]]></content:encoded>
			<wfw:commentRss>http://www.web-development-blog.com/archives/new-search-options-but-unrelated-results-in-google-blog-search/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Sending e-mails via SMTP with PHPmailer and Gmail</title>
		<link>http://www.web-development-blog.com/archives/send-e-mail-messages-via-smtp-with-phpmailer-and-gmail/</link>
		<comments>http://www.web-development-blog.com/archives/send-e-mail-messages-via-smtp-with-phpmailer-and-gmail/#comments</comments>
		<pubDate>Tue, 01 Sep 2009 19:40:25 +0000</pubDate>
		<dc:creator>Olaf</dc:creator>
				<category><![CDATA[Google services]]></category>
		<category><![CDATA[PHP scripts]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[google]]></category>
		<category><![CDATA[google applications]]></category>
		<category><![CDATA[hosting]]></category>
		<category><![CDATA[mail]]></category>
		<category><![CDATA[mail server]]></category>
		<category><![CDATA[smtp]]></category>

		<guid isPermaLink="false">http://www.web-development-blog.com/?p=393</guid>
		<description><![CDATA[Using the SMTP server from Gmail is a good choice for mail application with less than 500 recipients a day. This tutorials shows you how to send mail messages via SMTP using PHPmailer and Gmail.]]></description>
			<content:encoded><![CDATA[<p>These days I tried some plugin to send e-mail message within bbpress via SMTP. Since my domains email is hosted with Google applications I decided to send my messages via the SMTP server from GMail. I found several articles and tutorials, but a lot of them didn&#8217;t worked for me. </p>
<h3>Why using GMail for sending mail messages?</h3>
<p>First of all it&#8217;s FREE! Sure most website owners can use their own SMTP server for sending email messages from their website, but it makes sense even than to use Gmail for sending mail. The chance is big that your websites IP address is on a blacklist if your site is on hosted by a shared web hosting provider. If not or you host your site on your own server, there is always a risk that your IP address get blacklisted. Because of some limitations, the SMTP server from Google is a good choice applications with less than 500 recipients a day, check this <a href="http://mail.google.com/support/bin/answer.py?hl=en&#038;answer=22839" rel="nofollow">information</a> from the Google help pages.<span id="more-393"></span></p>
<h3>Requirements</h3>
<p>You need for this code example a PHP5 enabled web host (I tested only on Linux), the port 465 need to be open and of course you need a GMail or Google Apps account. </p>
<h3>SMTP for Gmail tutorial</h3>
<ol>
<li>If you don&#8217;t have one, <a href="http://mail.google.com/mail/signup" rel="nofollow">register</a> a GMail account or setup your domain for Google applications.</li>
<li><a href="http://sourceforge.net/projects/phpmailer/files/phpmailer%20for%20php5_6/" rel="nofollow">Download</a> a recent version of PHPMailer (I used the version 5.02)</li>
<li>Check with your web hosting provider if port 465 (TCP out) is open, if not ask him to open that port</li>
<li>Include the PHPMailer class file: <code>require_once('phpmailer/class.phpmailer.php');</code></li>
<li>Create those two constant variable to store your GMail login and password. Use the login for your Google application mail if you have one.

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #990000;">define</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'GUSER'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'you@gmail.com'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// Gmail username</span>
<span style="color: #990000;">define</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'GPWD'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'password'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// Gmail password</span></pre></div></div>

<li>Use the following function to send mail messages (add the function in one of your included files):

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">function</span> smtpmailer<span style="color: #009900;">&#40;</span><span style="color: #000088;">$to</span><span style="color: #339933;">,</span> <span style="color: #000088;">$from</span><span style="color: #339933;">,</span> <span style="color: #000088;">$from_name</span><span style="color: #339933;">,</span> <span style="color: #000088;">$subject</span><span style="color: #339933;">,</span> <span style="color: #000088;">$body</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> 
	<span style="color: #000000; font-weight: bold;">global</span> <span style="color: #000088;">$error</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$mail</span> <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> PHPMailer<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>  <span style="color: #666666; font-style: italic;">// create a new object</span>
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">IsSMTP</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// enable SMTP</span>
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">SMTPDebug</span> <span style="color: #339933;">=</span> <span style="color: #cc66cc;">0</span><span style="color: #339933;">;</span>  <span style="color: #666666; font-style: italic;">// debugging: 1 = errors and messages, 2 = messages only</span>
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">SMTPAuth</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">true</span><span style="color: #339933;">;</span>  <span style="color: #666666; font-style: italic;">// authentication enabled</span>
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">SMTPSecure</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'ssl'</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// secure transfer enabled REQUIRED for Gmail</span>
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Host</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'smtp.gmail.com'</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Port</span> <span style="color: #339933;">=</span> <span style="color: #cc66cc;">465</span><span style="color: #339933;">;</span> 
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Username</span> <span style="color: #339933;">=</span> GUSER<span style="color: #339933;">;</span>  
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Password</span> <span style="color: #339933;">=</span> GPWD<span style="color: #339933;">;</span>           
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">SetFrom</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$from</span><span style="color: #339933;">,</span> <span style="color: #000088;">$from_name</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Subject</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$subject</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Body</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$body</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">AddAddress</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$to</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span><span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Send</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$error</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'Mail error: '</span><span style="color: #339933;">.</span><span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">ErrorInfo</span><span style="color: #339933;">;</span> 
		<span style="color: #b1b100;">return</span> <span style="color: #009900; font-weight: bold;">false</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span> <span style="color: #b1b100;">else</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$error</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'Message sent!'</span><span style="color: #339933;">;</span>
		<span style="color: #b1b100;">return</span> <span style="color: #009900; font-weight: bold;">true</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>

<p>Most of the setting inside the function are required by GMail. While searching for tutorials I found articles with different settings for the port and security. My advice use them as in this tutorial.
</li>
<li>Call the function within your code:

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">smtpmailer<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'to@mail.com'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">''</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'from@mail.com'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'yourName'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'test mail message'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'Hello World!'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<p>Use this more &#8220;advanced&#8221; usage inside your application:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span>smtpmailer<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'to@mail.com'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'from@mail.com'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'yourName'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'test mail message'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'Hello World!'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #666666; font-style: italic;">// do something</span>
<span style="color: #009900;">&#125;</span>
<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span><span style="color: #990000;">empty</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$error</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #b1b100;">echo</span> <span style="color: #000088;">$error</span><span style="color: #339933;">;</span></pre></div></div>

</li>
</ol>
<h3>Advanced setup with fall-back SMTP server</h3>
<p>Because of the limit it might be useful to use a secondary SMTP server if the Gmail option didn&#8217;t send the message. For this functionality we need to replace the part with the SMTP settings a little bit. First create login/server variables for the 2nd SMTP server:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #990000;">define</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'SMTPUSER'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'you@yoursmtp.com'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// sec. smtp username</span>
<span style="color: #990000;">define</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'SMTPPWD'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'password'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// sec. password</span>
<span style="color: #990000;">define</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'SMTPSERVER'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'smtp.yoursmtp.com'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// sec. smtp server</span></pre></div></div>

<p>Next we need to create a if/else statement using the variables for the second server (replace).</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">function</span> smtpmailer<span style="color: #009900;">&#40;</span><span style="color: #000088;">$to</span><span style="color: #339933;">,</span> <span style="color: #000088;">$from</span><span style="color: #339933;">,</span> <span style="color: #000088;">$from_name</span><span style="color: #339933;">,</span> <span style="color: #000088;">$subject</span><span style="color: #339933;">,</span> <span style="color: #000088;">$body</span><span style="color: #339933;">,</span> <span style="color: #000088;">$is_gmail</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">true</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> 
	<span style="color: #000000; font-weight: bold;">global</span> <span style="color: #000088;">$error</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$mail</span> <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> PHPMailer<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">IsSMTP</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">SMTPAuth</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">true</span><span style="color: #339933;">;</span> 
	<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$is_gmail</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">SMTPSecure</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'ssl'</span><span style="color: #339933;">;</span> 
		<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Host</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'smtp.gmail.com'</span><span style="color: #339933;">;</span>
		<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Port</span> <span style="color: #339933;">=</span> <span style="color: #cc66cc;">465</span><span style="color: #339933;">;</span>  
		<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Username</span> <span style="color: #339933;">=</span> GUSER<span style="color: #339933;">;</span>  
		<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Password</span> <span style="color: #339933;">=</span> GPWD<span style="color: #339933;">;</span>   
	<span style="color: #009900;">&#125;</span> <span style="color: #b1b100;">else</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Host</span> <span style="color: #339933;">=</span> SMTPSERVER<span style="color: #339933;">;</span>
		<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Username</span> <span style="color: #339933;">=</span> SMTPUSER<span style="color: #339933;">;</span>  
		<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Password</span> <span style="color: #339933;">=</span> SMTPPWD<span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>        
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">SetFrom</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$from</span><span style="color: #339933;">,</span> <span style="color: #000088;">$from_name</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Subject</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$subject</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Body</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$body</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">AddAddress</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$to</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span><span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">Send</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$error</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'Mail error: '</span><span style="color: #339933;">.</span><span style="color: #000088;">$mail</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">ErrorInfo</span><span style="color: #339933;">;</span>
		<span style="color: #b1b100;">return</span> <span style="color: #009900; font-weight: bold;">false</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span> <span style="color: #b1b100;">else</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$error</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'Message sent!'</span><span style="color: #339933;">;</span>
		<span style="color: #b1b100;">return</span> <span style="color: #009900; font-weight: bold;">true</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>

<p>And use the function now as followed:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000088;">$msg</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'Hello World'</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$subj</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'test mail message'</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$to</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'to@mail.com'</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$from</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'from@mail.com'</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$name</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'yourName'</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span>smtpmailer<span style="color: #009900;">&#40;</span><span style="color: #000088;">$to</span><span style="color: #339933;">,</span> <span style="color: #000088;">$from</span><span style="color: #339933;">,</span> <span style="color: #000088;">$name</span><span style="color: #339933;">,</span> <span style="color: #000088;">$subj</span><span style="color: #339933;">,</span> <span style="color: #000088;">$msg</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'Yippie, message send via Gmail'</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span> <span style="color: #b1b100;">else</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span>smtpmailer<span style="color: #009900;">&#40;</span><span style="color: #000088;">$to</span><span style="color: #339933;">,</span> <span style="color: #000088;">$from</span><span style="color: #339933;">,</span> <span style="color: #000088;">$name</span><span style="color: #339933;">,</span> <span style="color: #000088;">$subj</span><span style="color: #339933;">,</span> <span style="color: #000088;">$msg</span><span style="color: #339933;">,</span> <span style="color: #009900; font-weight: bold;">false</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span><span style="color: #990000;">empty</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$error</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #b1b100;">echo</span> <span style="color: #000088;">$error</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span> <span style="color: #b1b100;">else</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'Yep, the message is send (after hard working)'</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>

<p><a href="http://www.freelancer.com/affiliates/olederer/" rel="nofollow"><img src="http://www.freelancer.com/img/affiliates/Freelancer_b2.gif" width=468 height=60 alt="Freelance Jobs" border=0></a></p>
<p>Both examples are very simple and demonstrate only how-to send mail messages via the SMTP server from Gmail. Of course the user can extend the code to handle HTML messages and attachments etc. If you have any issues with these examples, just let me know. Post a comment here or post to our partner <a href="http://www.finalwebsites.com/forums">PHP script forum</a>.</p>
<p><strong>Similar Posts:</strong>
<ul class="similar-posts">
<li><a href="http://www.web-development-blog.com/archives/php-mail-scripts-using-smtp-transport-a-guide-for-beginners/" rel="bookmark" title="April 12, 2010">PHP Mail Scripts using SMTP transport, a guide for beginners</a></li>
<li><a href="http://www.web-development-blog.com/archives/create-custom-backups-from-your-website-using-curl/" rel="bookmark" title="July 30, 2008">Create custom backups from your website using cURL</a></li>
<li><a href="http://www.web-development-blog.com/archives/jquery-contact-form-for-your-website/" rel="bookmark" title="January 11, 2010">jQuery Contact form for your website</a></li>
</ul>
<p><!-- Similar Posts took 4.556 ms --></p>
]]></content:encoded>
			<wfw:commentRss>http://www.web-development-blog.com/archives/send-e-mail-messages-via-smtp-with-phpmailer-and-gmail/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
		</item>
		<item>
		<title>AdSense for Domains, just another Domain Parking Service?</title>
		<link>http://www.web-development-blog.com/archives/adsense-for-domains-just-another-domain-parking-service/</link>
		<comments>http://www.web-development-blog.com/archives/adsense-for-domains-just-another-domain-parking-service/#comments</comments>
		<pubDate>Sun, 22 Feb 2009 19:44:17 +0000</pubDate>
		<dc:creator>Olaf</dc:creator>
				<category><![CDATA[Advertising]]></category>
		<category><![CDATA[Google services]]></category>
		<category><![CDATA[adsense]]></category>
		<category><![CDATA[dns]]></category>
		<category><![CDATA[domain names]]></category>
		<category><![CDATA[domain parking]]></category>
		<category><![CDATA[traffic]]></category>

		<guid isPermaLink="false">http://www.web-development-blog.com/?p=245</guid>
		<description><![CDATA[Actually &#8220;Adsense for domains&#8221; is just like most of the other domain parking services. So why should we park our unused domain names with Google? For a long time I never used any domain parking services because I didn&#8217;t believed in that product. I checked the first time &#8220;Revenue Parking&#8221; provided by my domain registration [...]]]></description>
			<content:encoded><![CDATA[<blockquote><p>Actually &#8220;Adsense for domains&#8221; is just like most of the other domain parking services. So why should we park our unused domain names with Google?</p></blockquote>
<p>For a long time I never used any domain parking services because I didn&#8217;t believed in that product. I checked the first time &#8220;Revenue Parking&#8221; provided by my domain registration provider Dynadot, after several month I was not very satisfied with that product. Another point to not use that kind of service was that you need host a domain name with the same provider if you want to their domain parking service.</p>
<p><a href="http://www.kqzyfj.com/click-2408474-10384684" target="_top" rel="nofollow"><br />
<img src="http://www.awltovhc.com/image-2408474-10384684" width="468" height="60" alt="Resell Domains for GoDaddy.com " border="0"/></a></p>
<p>Several weeks ago I read on the Adsense blog about this new service and forget it already because the &#8220;Adsense for domains&#8221; was not yet available in my account. By accident I noticed the new link on my Adsense setup page and started to plat a little with this new product.</p>
<h3>Add domain names and configuration</h3>
<p>Adding domain names is quite simple just add your name together with the language and in the next step you get the information for the DNS settings. As with most other parking services you don&#8217;t need to change the name server entries. You need to enter at least 4 A-records and one CNAME for the &#8220;www&#8221; sub-domain. The CNAME holds also your Adsense Publisher ID which should be used for the validation that a domain belongs to your Adsense account. <span id="more-245"></span>For the DNS configuration you will find help files with information how to change the DNS with the bigger domain name provider. I created one account on my own server and add other domain names as domain pointer. This way I&#8217;m able to copy past the information directly into &#8220;named&#8221; data base files.</p>

<a href='http://www.web-development-blog.com/wp-content/uploads/2009/02/setup.jpg' rel='shadowbox[album-245];player=img;' title='setup'><img width="150" height="150" src="http://www.web-development-blog.com/wp-content/uploads/2009/02/setup-150x150.jpg" class="attachment-thumbnail" alt="setup" title="setup" /></a>
<a href='http://www.web-development-blog.com/wp-content/uploads/2009/02/style.jpg' rel='shadowbox[album-245];player=img;' title='style'><img width="150" height="150" src="http://www.web-development-blog.com/wp-content/uploads/2009/02/style-150x150.jpg" class="attachment-thumbnail" alt="style" title="style" /></a>
<a href='http://www.web-development-blog.com/wp-content/uploads/2009/02/config.jpg' rel='shadowbox[album-245];player=img;' title='config'><img width="150" height="150" src="http://www.web-development-blog.com/wp-content/uploads/2009/02/config-150x150.jpg" class="attachment-thumbnail" alt="config" title="config" /></a>
<a href='http://www.web-development-blog.com/wp-content/uploads/2009/02/report.jpg' rel='shadowbox[album-245];player=img;' title='report'><img width="150" height="150" src="http://www.web-development-blog.com/wp-content/uploads/2009/02/report-150x150.jpg" class="attachment-thumbnail" alt="report" title="report" /></a>

<h3>Validation process and add styles</h3>
<p>After you add the domain to your account and the DNS configuration is done it needs a few hours until the validation is done. At the moment you need to check the your account by yourself and if needed to re-validate there is an option too. After validation you&#8217;re able to add channels to your parked domain name: &#8220;I suggest to do that other wise you didn&#8217;t know which domain performs very well and which not&#8221;. Tray also to enter some keywords to your domain name and maybe you like to change the style from your parking page. Right parking pages are not very &#8220;stylish&#8221;, but maybe some custom colors will let the visitor generate more page views.</p>
<h3>Reports and earnings</h3>
<p>&#8220;Adsense for domains&#8221; is  (great) CPM based advertising. It look to me as for regular ads, that some domain names perform better some than another. Just like with content related ads Google will show ads with higher and lower revenue. The reports are the same as for the other ads (content, search&#8230;) and doesn&#8217;t need any explanation. At the moment I can&#8217;t see if impressions from the landing page will earn more or less than impressions from other result pages. There is no information about the how many clicks are generated.</p>
<h3>Rules for publishers</h3>
<p>There are some new rules for the &#8220;domain park&#8221; publisher, since the earnings are CPM based it&#8217;s not allowed to redirect traffic to that page, advertising for parked domain isn&#8217;t allowed&#8230;</p>
<p>I use the Adsense product for names which are not used anymore and still have some traffic. I noticed that some domain perform much better than earlier with content ads.</p>
<blockquote><p>What is your experience with &#8220;Adsense for domains&#8221;?</p></blockquote>
<p><strong>Similar Posts:</strong>
<ul class="similar-posts">
<li><a href="http://www.web-development-blog.com/archives/sponsored-posting-useful-domain-name-tools/" rel="bookmark" title="March 28, 2007">Domain Name Research and Monetization Tools</a></li>
<li><a href="http://www.web-development-blog.com/archives/registering-a-domain-name-important-considerations/" rel="bookmark" title="September 10, 2007">Registering a domain name &#8211; important considerations</a></li>
<li><a href="http://www.web-development-blog.com/archives/adsense-for-wordpress-5-plugins-reviewed/" rel="bookmark" title="November 30, 2009">Adsense for WordPress &#8211; 5 Plugins reviewed</a></li>
</ul>
<p><!-- Similar Posts took 3.558 ms --></p>
]]></content:encoded>
			<wfw:commentRss>http://www.web-development-blog.com/archives/adsense-for-domains-just-another-domain-parking-service/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
		</item>
	</channel>
</rss>
<!-- WP Super Cache is installed but broken. The path to wp-cache-phase1.php in wp-content/advanced-cache.php must be fixed! -->