<?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>Nedko &#187; Blog</title>
	<atom:link href="http://www.nedkoko.com/blog/feed" rel="self" type="application/rss+xml" />
	<link>http://www.nedkoko.com</link>
	<description>A different point of view</description>
	<lastBuildDate>Mon, 08 Mar 2010 21:05:16 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Log4J Exceptions &#8211; Stack Trace Output and Handling</title>
		<link>http://www.nedkoko.com/blog/development/log4j-exceptions-stack-trace-output-and-handling</link>
		<comments>http://www.nedkoko.com/blog/development/log4j-exceptions-stack-trace-output-and-handling#comments</comments>
		<pubDate>Mon, 08 Mar 2010 21:05:16 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[General]]></category>
		<category><![CDATA[architecture]]></category>
		<category><![CDATA[logging]]></category>

		<guid isPermaLink="false">http://www.nedkoko.com/?p=22</guid>
		<description><![CDATA[During my professional career I have become accustomed to the development tools that make the engineer's job much easier. On the other hand I've come to the realization that little time and attention is being spent on optimization and proper use of those tools. While there is plenty of information out there on framework comparisons, guides, APIs, and the like very few products seem to adopt the best practices and the tier two functionality slips through the cracks of the Q&#038;A process. This is usually the case with logging.]]></description>
			<content:encoded><![CDATA[<h2>Overview</h2>
<p>During my professional career I have become accustomed to the development tools that make the engineer&#8217;s job much easier. On the other hand I&#8217;ve come to the realization that little time and attention is being spent on optimization and proper use of those tools. While there is plenty of information out there on framework comparisons, guides, APIs, and the like very few products seem to adopt the best practices and  the tier two functionality slips through the cracks of the Q&amp;A process. This is usually the case with logging.<br />
<a href="http://logging.apache.org/log4j/">Log4J</a> is the status quo when it comes to logging in Java. With the expanded mainstream popularity the framework which has been branched in C++ (<a href="http://logging.apache.org/log4cxx/">Log4cxx</a>) ,  C#/.NET (<a href="http://logging.apache.org/log4net/">Log4Net</a>) and even PHP (<a href="http://incubator.apache.org/log4php/">Log4php</a>) has made it easy to add logging to multi tier applications. The advantage of having a very granular approach with different log levels (DEBUG, INFO, ERROR, etc.) and the Logger package inheritance make it a flexible tool. Without getting into details on the <a href="http://logging.apache.org/log4j/1.2/manual.html">configuration</a> and how to <a href="http://logging.apache.org/log4j/1.2/manual.html">get started</a> I want to spend time on the proper Logger initialization and use for exception handling.</p>
<h2>Log4J Logger</h2>
<p>As described in the <a href="http://logging.apache.org/log4j/1.2/apidocs/org/apache/log4j/Logger.html">Logger API</a> we can get our Logger initialized inside the class in one of several ways the most common of which are:</p>
<p>- using the Class object</p>
<pre class="brush: java;">
Logger log = Logger.getLogger(getClass());
</pre>
<p>- using a string</p>
<pre class="brush: java;">
Logger log = Logger.getLogger(getClass().getName());
</pre>
<p>or</p>
<pre class="brush: java;">
Logger log = Logger.getLogger(&quot;com.java.foo.MyClass&quot;);
</pre>
<p>Once we have a logger instance we can easily log messages with different threshold:</p>
<pre class="brush: java;">
Foo foo = new Foo();
log.info(&quot;Created object foo: &quot; + foo.toString());
</pre>
<p>or</p>
<pre class="brush: java;">
if(log.isDebugEnabled())
{
	//do something
	log.debug(&quot;Result: &quot; + foo.getResult());
}
</pre>
<h2>Exception handling</h2>
<p>It gets more interesting when we get to exception handling. In the regular try catch scenario we usually deal with some exception where we want to collect some output about what happened and where. A lot of times developers are tempted to use exception.getMessage() which is often empty or yet worse call exception.printStackTrace() which actually prints to the standard output rather than our log file. In order to successfully print the exception message and the stack trace we can add the exception to the logger output by doing this instead:</p>
<pre class="brush: java;">
try
{
	computeInterestRates();
}
catch(Exception e)
{
	//something went wrong - log an error
	log.error(&quot;Error during RateCalc: &quot;, e);
}
</pre>
<h2>Conclusion</h2>
<p>It is easy to get lost in requirements and miss on some of the essential product functionality. The proper use of logging helps reduce and eliminate defects in the lifecycle of the software and be a life saver in the long run. Make sure that you properly handle all logging. Keep in mind that the overuse of logging has a detrimental effect on performance so use it sparingly. For more information see the <a href="http://logging.apache.org/log4j/1.2/manual.html">Log4j Official Documentation</a>.</p>
<input id="gwProxy" type="hidden" />
<input id="jsProxy" onclick="jsCall();" type="hidden" />
<input id="gwProxy" type="hidden" />
<input id="jsProxy" onclick="jsCall();" type="hidden" />
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.nedkoko.com%2Fblog%2Fdevelopment%2Flog4j-exceptions-stack-trace-output-and-handling&amp;linkname=Log4J%20Exceptions%20%26%238211%3B%20Stack%20Trace%20Output%20and%20Handling"><img src="http://www.nedkoko.com/wp/wp-content/plugins/add-to-any/share_save_256_24.png" width="256" height="24" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.nedkoko.com/blog/development/log4j-exceptions-stack-trace-output-and-handling/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>J2EE classloading &#8211; java.lang.LinkageError</title>
		<link>http://www.nedkoko.com/blog/development/j2ee-classloading-javalanglinkageerror</link>
		<comments>http://www.nedkoko.com/blog/development/j2ee-classloading-javalanglinkageerror#comments</comments>
		<pubDate>Wed, 12 Aug 2009 18:23:28 +0000</pubDate>
		<dc:creator>Nedko</dc:creator>
				<category><![CDATA[Development]]></category>

		<guid isPermaLink="false">http://www.nedkoko.com/blog/2009/08/12/j2ee-classloading-javalanglinkageerror/</guid>
		<description><![CDATA[Recently while working on a java enterprise application I came upon a runtime error which later inspired this very post. What will follow will also give you a taste of what proper Maven dependency management should look like. The problem in question was a library call which caused the following to be spit in my [...]]]></description>
			<content:encoded><![CDATA[<p>Recently while working on a java enterprise application I came upon a runtime error which later inspired this very post. What will follow will also give you a taste of what proper Maven dependency management should look like. The problem in question was a library call which caused the following to be spit in my error logs:</p>
<blockquote><p><strong>Caused by: java.lang.LinkageError: loader constraints violated when linking javax/activation/DataHandler class</strong><span id="more-19"></span></p></blockquote>
<p>Translation: This is typically caused to be thrown when two different classloaders load different versions of the same class (different signatures). The underlying cause is essentially including two versions of the same class in your CLASSPATH. Most often the underlying reason is including a JAR file as a dependency in your WAR or EAR which is already included as part of your Servlet Container (my development container happens to be <a href="http://www.jboss.com/" target="_blank">JBoss</a>) or your JVM.<br />
A quick search on <a href="http://www.findjar.com/class/javax/activation/DataHandler.html" target="_blank">findjar.com</a> established that my problem is caused by activation.jar which happens to be included both in my project and the JBoss lib. A quick way to verify this is to extract the EAR or WAR file and have a look for the jar question. In my case I was able to find it in both WEB-INF/lib and JBOSS/lib. A quick fix or a proof of the solution is simply removing one of the instances. For me removing the jar from the EAR proved to be the solution.<br />
Since I like automation when it comes to dependency management I am using <a href="http://maven.apache.org/" target="_blank">Maven</a> to alleviate all the hassles of the manual equivalent. That means that I need to trace which of my build modules includes the jar in question. This is done by building the <a href="http://maven.apache.org/plugins/maven-dependency-plugin/" target="_blank">Maven</a><a href="http://maven.apache.org/plugins/maven-dependency-plugin/" target="_blank"> </a><a href="http://maven.apache.org/plugins/maven-dependency-plugin/" target="_blank">dependency tree</a>:</p>
<blockquote><p><strong>mvn dependency:tree</strong></p></blockquote>
<p>or tunnel the output to a text file which you can examine in your favorite editor (recommended)</p>
<blockquote><p><strong>mvn dependency:tree &gt; tree.txt</strong></p></blockquote>
<p>Here it&#8217;s worth noting that the dependency feature parameter &#8220;outputFile&#8221; is not working at the time of writing due to a <a href="http://jira.codehaus.org/browse/MDEP-161" target="_blank">known bug</a>. After building and searching the tree I can easily identify all the references: javax.xml.bind and javax.xml.ws<br />
Now in order to fix the problem all I need to do is provide the exclusion to both dependencies in my pom.xml:</p>
<blockquote><p><strong><em>&lt;exclusions&gt;</em></strong><br />
<strong><em> &lt;exclusion&gt;</em></strong><br />
<strong><em> &lt;groupId&gt;javax.activation&lt;/groupId&gt;</em></strong><br />
<strong><em> &lt;artifactId&gt;activation&lt;/artifactId&gt;</em></strong><br />
<strong><em> &lt;/exclusion&gt;</em></strong><br />
<strong><em> &lt;/exclusions&gt;</em></strong></p></blockquote>
<p>Now my dependency looks like this:</p>
<blockquote><p><em><strong>&lt;dependency&gt;</strong></em><br />
<em><strong> &lt;groupId&gt;com.sun.xml.bind&lt;/groupId&gt;</strong></em><br />
<em><strong> &lt;artifactId&gt;jaxb-impl&lt;/artifactId&gt;</strong></em><br />
<em><strong> &lt;version&gt;2.0.3&lt;/version&gt;</strong></em><br />
<em><strong> &lt;exclusions&gt;</strong></em><br />
<em><strong> &lt;exclusion&gt;</strong></em><br />
<em><strong> &lt;groupId&gt;javax.activation&lt;/groupId&gt;</strong></em><br />
<em><strong> &lt;artifactId&gt;activation&lt;/artifactId&gt;</strong></em><br />
<em><strong> &lt;/exclusion&gt;</strong></em><br />
<em><strong> &lt;/exclusions&gt;</strong></em><br />
<em><strong> &lt;/dependency&gt;</strong></em></p></blockquote>
<p>Before I run a full build it&#8217;s best to verify that there are no more references of activation.jar in my tree by creating the dependency tree again. With that out of the way I am ready to build and deploy my EAR to test the solution. For more on maven <a href="http://maven.apache.org/guides/introduction/introduction-to-dependency-mechanism.html" target="_blank">dependency mechanism</a> and <a href="http://maven.apache.org/guides/introduction/introduction-to-optional-and-excludes-dependencies.html" target="_blank">managing exclusions</a> please refer to the <a href="http://maven.apache.org/run-maven/index.html" target="_blank">Maven documentation</a>.</p>
<p class="zemanta-pixie"><img src="http://img.zemanta.com/pixy.gif?x-id=dd5d7eaf-fd6b-842f-bc76-264a7681d328" class="zemanta-pixie-img" /></p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.nedkoko.com%2Fblog%2Fdevelopment%2Fj2ee-classloading-javalanglinkageerror&amp;linkname=J2EE%20classloading%20%26%238211%3B%20java.lang.LinkageError"><img src="http://www.nedkoko.com/wp/wp-content/plugins/add-to-any/share_save_256_24.png" width="256" height="24" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.nedkoko.com/blog/development/j2ee-classloading-javalanglinkageerror/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Face Detection Technology</title>
		<link>http://www.nedkoko.com/blog/development/face-detection-technology</link>
		<comments>http://www.nedkoko.com/blog/development/face-detection-technology#comments</comments>
		<pubDate>Mon, 04 Aug 2008 20:00:12 +0000</pubDate>
		<dc:creator>Nedko</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://www.nedkoko.com/blog/2008/08/04/face-detection-technology/</guid>
		<description><![CDATA[Research has shown that 70% of the pictures we take feature people. Face detection in software in digital processors can greatly enhance the quality of images and help describe the content. Why not? While humans can easily identify objects in a photograph it takes a lot more to teach a machine how to do that [...]]]></description>
			<content:encoded><![CDATA[<p>Research has shown that 70% of the pictures we take feature people. Face detection in software in digital processors can greatly enhance the quality of images and help describe the content. Why not? While humans can easily identify objects in a photograph it takes a lot more to teach a machine how to do that and most of all &#8230;do it well. <span id="more-18"></span><br />
First off it&#8217;s very important not to confuse the term &#8220;face detection&#8221; with &#8220;face recognition&#8221;. Although they sound very similar they are two completely different things. Face recognition is the ability to identify or verify a person from an image or video by facial features. Face detection is the ability to determine the location and size of human faces in images and video. Needless to say face detection is an important prerequisite for face recognition and as such plays an important role in recent research as government agencies are struggling to provide safe, inexpensive, and reliable security.<br />
Before I jump into more details about the process and the techniques used I wanted to share my pure amazement when I found out that my digital camera&#8217;s face detection is racist. That&#8217;s right &#8211; while taking pictures at a party I noticed that my Canon camera cannot detect faces very well when the subject&#8217;s skin color happens to be other than white. Furthermore I realized that this is true even for mixed pictures containing different people. Acknowledging this interesting fact I was not very surprised when I started to look in the techniques used for face detection.<br />
Digital cameras use face detection technology to adjust the focus and exposure of subjects and also allow the photographer to zoom in the faces while shooting. This is accomplished by dynamic scanning of the image and detection of patterns by the digital processor. There are many different techniques used in detection &#8211; some easy and some hard. Of course the easiest way is when we have images in an environment with plain monocolor or controlled background. Another approach is trying to recognize the certain facial features: head generally round shape, nose, eyes, chin, mouth, and ears. A similar approach detects objects in motion &#8211; the face is almost always a moving element in photos or videos. And if you thought that color needs to be somehow involved in our mystery you guessed right. Another very wide spread face detection technique is finding faces by color. This is generally a two step process which first finds groupings or regions likely to contain skin and then tries to analyze them and extract information to identify a face. Here come the disadvantages: this method requires color images, does not work very well with various kinds of skin color and the performance varies under changing lighting conditions.<br />
The conclusion: don&#8217;t be surprised next time your camera favors some of your friends over others &#8211; you know why.</p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.nedkoko.com%2Fblog%2Fdevelopment%2Fface-detection-technology&amp;linkname=Face%20Detection%20Technology"><img src="http://www.nedkoko.com/wp/wp-content/plugins/add-to-any/share_save_256_24.png" width="256" height="24" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.nedkoko.com/blog/development/face-detection-technology/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>iGoogle Review</title>
		<link>http://www.nedkoko.com/blog/uncategorized/igoogle-review</link>
		<comments>http://www.nedkoko.com/blog/uncategorized/igoogle-review#comments</comments>
		<pubDate>Mon, 12 May 2008 19:22:49 +0000</pubDate>
		<dc:creator>Nedko</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.nedkoko.com/blog/2008/05/12/igoogle-review/</guid>
		<description><![CDATA[Along with the catchy name iGoogle has  succeeded to put &#8216;personalized&#8217; in search. While the idea is nothing new and has been present for long in competitor sites (My Yahoo! and Microsoft Life are a two examples which need no introduction) Google has been able to put a different spin on the concept.
To help [...]]]></description>
			<content:encoded><![CDATA[<p>Along with the catchy name iGoogle has  succeeded to put &#8216;personalized&#8217; in search. While the idea is nothing new and has been present for long in competitor sites (My Yahoo! and Microsoft Life are a two examples which need no introduction) Google has been able to put a different spin on the concept.<span id="more-17"></span></p>
<p>To help clearly define and put the focus of it&#8217;s customization effort Google renamed the &#8216;Personalized Home&#8217; page to <a href="http://www.youtube.com/watch?v=Pbf0dlESX8E">iGoogle</a>. Along with that came some new features which were along the lines of the rest of the Web 2.0 world: personalization with the portal feel while being able to aggregate all Google features like web, images, mail, calendar, maps, news and more. The concept of taking full advantage of localization, syndication, collaboration and bringing more web to the user by having gadgets really took off and has proven to be the fastest growing company product for 2006.</p>
<p>One thing that really stands out about the platform is that it has almost no learning curve and it allows the user to define the boundaries within which it will be used. A user is easily able to use the service without even signing up with an account (using cookies) but if you want to take personalization to the next level you can sign up and use it on multiple computers, customize it even more and bring social networking in the picture. Adding the ability to collaborate (discuss stocks or share documents for examle) and get updates about your friends&#8217; photo album or new widgets that they have added is like taking all the applications you use, putting them on the web and running a cross layer of social networking to form something bigger than the sum of its parts.</p>
<p>The widgets concept is great and while it still has some rough edges it definitely provides a great start for organizing a dashboard with customizable layout and content spread on optionally multiple tabs. The rich library of existing widgets will satisfy almost any taste and even for the pickiest users there is an opportunity to create their own widgets by using the Widget Maker feature which provides a nice widget API (more on that in my next post). While talking about customization I can&#8217;t help mentioning the themes which offer the extra touch of personality. Unless you are one of these boring people like me you might want to pick one of the many themes which nicely change the default white frame and add the extra touch of personality without taking away from the content. As a new addition Google has even gone a step further including the so called <a href="http://wwwww.google.com/help/ig/art/gallery.html">Artist Themes</a> which represent the artwork of world class artist.</p>
<p>In conclusion iGoogle introduces a new way of looking at web + search and re-defines customization with features like location-based personalized search. This direction will be very important for Search 2.0 as it reaches more and more mobile devices. On the other hand a lot is left to be desired in improving the functionality of widgets: creating anything different than the boring RSS or a poorly styled functionally handicapped widget.</p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.nedkoko.com%2Fblog%2Funcategorized%2Figoogle-review&amp;linkname=iGoogle%20Review"><img src="http://www.nedkoko.com/wp/wp-content/plugins/add-to-any/share_save_256_24.png" width="256" height="24" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.nedkoko.com/blog/uncategorized/igoogle-review/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Blue Ray Vs. HD DVD &#8211; What did Sony learn from Betamax Vs. VHS</title>
		<link>http://www.nedkoko.com/blog/uncategorized/blue-ray-vs-hd-dvd-whad-did-sony-learn-from-betamax-vs-vhs</link>
		<comments>http://www.nedkoko.com/blog/uncategorized/blue-ray-vs-hd-dvd-whad-did-sony-learn-from-betamax-vs-vhs#comments</comments>
		<pubDate>Thu, 28 Feb 2008 21:58:32 +0000</pubDate>
		<dc:creator>Nedko</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.nedkoko.com/blog/2008/02/28/blue-ray-vs-hd-dvd-whad-did-sony-learn-from-betamax-vs-vhs/</guid>
		<description><![CDATA[At the time I am writing this the battle is over and the dust is starting to settle as Toshiba just waived the white flag and announced that they are going to discontinue their HD DVD campaign and stop manufacturing HD DVD products. And most likely as you are reading this HD DVD will just [...]]]></description>
			<content:encoded><![CDATA[<p>At the time I am writing this the battle is over and the dust is starting to settle as Toshiba just waived the white flag and announced that they are going to discontinue their HD DVD campaign and stop manufacturing HD DVD products. And most likely as you are reading this HD DVD will just be a piece of history &#8230;important history which goes long before I was even  born &#8211; these are the days of the magnetic media revolution; the days when VHS players could reach ridiculous prices and could cost &#8211; up to half the price of a luxury vehicle.<span id="more-13"></span></p>
<p>While DVD was great while it lasted and marked one of the greatest successes in the history of consumer electronics it was clear that its days were numbered. The standard definition that DVD had to offer was not enough to satisfy the likes of Hollywood. With technology racing at an unimaginable rate and HD video and audio reaching living rooms around the world the world for the next generation high definition format was started. That is a round 2 for Sony and the long forgotten Betamax Vs. Video Home System (or VHS as we all know it) for standard domination. The last time around Sony&#8217;s Betamax lost the battle despite being technologically superior. Better quality had recording time as a trade-off. The majority of consumers did not want to commit to a standard and movies were offered for both. Unlike this time the battle continued much longer and finally VHS&#8217;s dominant market share, higher recording capacity, and lower media costs forces Sony to pull out. Well, apparently the folks at Sony have learned a few lessons. Although Blue Ray still has a higher cost and the early momentum that HD DVD generated this time we have a much more competitive product. Starting with much higher capacity [50Gb for a dual layer compared to 30Gb for Toshiba's HD DVD] Blue Ray seems technologically superior. This time Sony took a different approach and overcame the somewhat established HD DVD lead by spending most time and applying pressure to the movie studios themselves. The tight competition forced studios to offer movies in one format or the other but not both. Same was valid for manufacturer support where Blue Ray had better success. All the success could also be partially credited to region coded support and better digital right management and copy protection. At the end it came down to Warner Brothers followed by Wal Mart who joined Sony and agreed to offer movies exclusively in Blue Ray. While those two add just one more to the count they represent 80% and 32% respectively of the market share in their industry which makes the decisions huge. Toshiba knew that was a big sway on Blue Ray&#8217;s direction &#8211; it was more than they could handle. Disappointing signs from investors forced the giant to discontinue the efforts to revive the initial momentum and under such pressures Toshiba made a press release announcing the end of the Blue Ray Vs. HD DVD war. Although Sony was ready for a long battle it can now claim the victory.</p>
<p>The score is not 1:1 and the question &#8220;Is &lt;insert movie&gt; coming to Blu-ray?&#8221; in section <a href="http://www.blu-ray.com/faq/">4.3 of the Blue Ray FAQ</a> much easier to answer. Lesson learned for Sony &#8211; what goes around comes around.</p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.nedkoko.com%2Fblog%2Funcategorized%2Fblue-ray-vs-hd-dvd-whad-did-sony-learn-from-betamax-vs-vhs&amp;linkname=Blue%20Ray%20Vs.%20HD%20DVD%20%26%238211%3B%20What%20did%20Sony%20learn%20from%20Betamax%20Vs.%20VHS"><img src="http://www.nedkoko.com/wp/wp-content/plugins/add-to-any/share_save_256_24.png" width="256" height="24" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.nedkoko.com/blog/uncategorized/blue-ray-vs-hd-dvd-whad-did-sony-learn-from-betamax-vs-vhs/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Google Apps Review &#8211; Should you switch?</title>
		<link>http://www.nedkoko.com/blog/uncategorized/google-apps-review-should-you-switch</link>
		<comments>http://www.nedkoko.com/blog/uncategorized/google-apps-review-should-you-switch#comments</comments>
		<pubDate>Fri, 21 Dec 2007 16:12:18 +0000</pubDate>
		<dc:creator>Nedko</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.nedkoko.com/blog/2007/12/21/google-apps-review-should-you-switch/</guid>
		<description><![CDATA[Google Apps is a service providing customized solution for your company using several of Google&#8217;s products. By using Google Apps for your domain you can take advantage of Google&#8217;s mail service (Gmail) as well as several web applications including Google Calendar, Google Docs, Google Talk. Since Gmail now supports both POP and IMAP functionality it&#8217;s [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.nedkoko.com/blog/images/question.gif" title="should you switch to google apps" alt="should you switch to google apps" align="left" border="1" height="250" hspace="4" vspace="4" width="200" />Google Apps is a service providing customized solution for your company using several of Google&#8217;s products. By using Google Apps for your domain you can take advantage of Google&#8217;s mail service (Gmail) as well as several web applications including Google Calendar, Google Docs, Google Talk. Since Gmail now supports both POP and IMAP functionality it&#8217;s worth considering switching your in-house email solution to Google Apps and offload the need for hardware, software, administration and maintenance, backups etc. For those of you who are already thinking about it &#8211; keep reading.<span id="more-12"></span></p>
<p>After a couple of days researching what exactly Google Apps has to offer and countless hours of searching for feedback from people with first hand experience on the matter I decided to bite the bullet and pull the plug on my good &#8216;ol mail server. My main motivation was the fact that i can try it for free and even continue using it for free as long as my domain met certain criteria. On top of that Google provided me with scheduling and collaboration tools using a one-size-fits-all approch. At that point I had heard enough and was ready to get my hands dirty with Google Apps or at least as dirty as a keyboard, mouse and 2 hours of my free time will allow. But before I continue sharing my adventure I wanted to share some of the pros and cons of using Google Apps.</p>
<p><strong><br />
</strong></p>
<h2><strong>Pros:</strong></h2>
<p><strong> </strong></p>
<p>Most apparently you get a nice, production grade Gmail email service with a 99.9% uptime promise, backups, security, spam filters,  web inteface people are familiar with.</p>
<p><strong>Cost</strong>. The cost of the implementation and the  ROI is very low (50$ per user per account per user &#8211; that excludes aliases and lists) for the Premier edition and FREE for the Standard version. Compared to other combinations requiring some combination of software + hardware + support you get the most bang for your buck.</p>
<p><strong>Ease of use</strong>.  Needless to say nowadays it&#8217;s hard to find a person not familiar with Google&#8217;s Gmail and their slick and easy to use web interface. This makes the transition for any institution a breeze and the time spent in user training limited.</p>
<p><strong>Ease of administration</strong> &#8230;administration? What&#8217;s that? No, but honestly  adding users is a breeze as well as user aliases and list administration. Of course there is always more to be expected especially when it comes to granularity and the concept of groups but it is my belief that there is already somebody in cube scetching and coding that implementation.</p>
<p><strong>Premium Edition FREE</strong>. If you satisfy certain requirements you can use Google Apps Premier absolutely free. Those include registered non-profits and educational institutions.</p>
<p><strong>Built-in Security</strong> &#8211; Google uses secure connections and data redundancy. Through the use of protocols such as SSL and TLS you can make sure your data is protected. In certain situations this extra security can pose a problem with existing applications which make use of SMTP but don&#8217;t provide secure connection but there are possible workaronds.</p>
<p><strong>Physical security</strong> &#8211; your data is stored on a server in a data center with top of the line protection from any natural events from floods and fire to earthquakes.</p>
<p><strong>Calendar functionality</strong> by itself is a great feature which again most people use and are familiar with the interface from their personal accounts. The integration under the same umbrella comes handy and the Premier edition includes goodies like room and resource scheduling.</p>
<p><strong>Great collaboration tools</strong> like document sharing, simultaneous editing, web publishing and chat. It&#8217;s hard to express in words the time savings and convenience when you see a combination of these tools in action &#8211; whether you have 20 people editing the same document or just want to send a message to somebody you have everything you need.</p>
<p><strong>A free replacement for an Office suite</strong>. Although Google Docs was not created as a perfect replacement of applications like Microsoft Office in mind it provides most of the features most users are likely to use. Except the fact that Google really missed the memo on a presentation replacement application their solution focuses on collaboration, central data storage, and 24/7 availability.</p>
<p><strong>More</strong> of the bonus features include: API, Single Sign-On solution, super easy email migration,  support for email gateway</p>
<h2><strong>Cons:</strong></h2>
<p><strong>Control</strong>. Well,  of course by committing you have less control in the decision making process but you can try and then always switch to another solution</p>
<p><strong>You get what you pay for</strong>. If you don&#8217;t have the Premier edition free support is to no avail. That means that you will have to spend time researching when problems arise and most likely end up paying when there is nothing you can do about the problems</p>
<p><strong>Maturity</strong>. Be mindful that Google Apps is a project in progress and is not very mature. That means that it is incomplete and lacks certain functionality which you might expect.</p>
<p><strong>Support</strong> &#8230;or the lack thereof is one important thing to mention. See, even if you use the premium edition and pay all the fees you can only get so much. Getting to talk to a real person is off limits and all the automated phone service refers you is help and forum URLs. Your only chance to get some personal attention is to use the ticketing system submit form and prey that your issue gets looked at pretty soon. Make sure you bookmark this page https://mail.google.com/support/bin/request.py?contact_type=bugs&amp;ctx=bugflow_register08 as it will be your only point of contact with the Gods of Email.</p>
<p><strong>Executables</strong>. Watch out for executable files &#8211; Google will not let them in even if you try to trick it by archiving it. Although sending executables through email is not a good practice as well as coaching your users to open executable extensions this can be a little annoying.</p>
<p><strong>CSS</strong>. Not that this is exactly a very big deal for most people and they might as well never notice it but Gmail&#8217;s web interface will strip headers and almost all CSS from an email sent as HTML. For udnerstandable reasons they don&#8217;t want layout hiccups but some users can find that a bit inconvenient.</p>
<p><strong>Privacy</strong> is a major concern for any organization especially when it has to do with sensitive company data and  intellectual property.</p>
<p><strong>Regulatory compliance</strong>. Before I continue any further let me just say that if your organization requires regulatory compliance of any sort which is often the case with certain branches of government, healthcare, and the financial industry you can automatically forget about it &#8211; Google Apps does not comply with the storage, transfer, filtering, privacy and disaster recovery requirements for those sectors.</p>
<p><strong>Ads</strong>. When using the web interface you might have to see a couple of advertisements. Unfortunately the free edition does not have the option to turn them off but after all there is no such thing as free lunch.</p>
<p><strong>SMTP limit</strong>. If you really read the fineprint you will know &#8230;or you will find out later that Google&#8217;s SMTP service has a restriction to send only up to 500 emails per day for a particular account. While this is enough for the average Joe in your office it might pose a risk if you are using any automated email services and notification in your organization. Again the workaround is using a separate SMTP server as an email proxy.</p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.nedkoko.com%2Fblog%2Funcategorized%2Fgoogle-apps-review-should-you-switch&amp;linkname=Google%20Apps%20Review%20%26%238211%3B%20Should%20you%20switch%3F"><img src="http://www.nedkoko.com/wp/wp-content/plugins/add-to-any/share_save_256_24.png" width="256" height="24" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.nedkoko.com/blog/uncategorized/google-apps-review-should-you-switch/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Multipart MIME email example in PHP</title>
		<link>http://www.nedkoko.com/blog/development/multipart-mime-email-example-in-php</link>
		<comments>http://www.nedkoko.com/blog/development/multipart-mime-email-example-in-php#comments</comments>
		<pubDate>Fri, 23 Nov 2007 17:54:46 +0000</pubDate>
		<dc:creator>Nedko</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[HOW TOs]]></category>

		<guid isPermaLink="false">http://www.nedkoko.com/blog/2007/11/23/multipart-mime-email-example-in-php/</guid>
		<description><![CDATA[ Let&#8217;s see how we can use some simple tools and create a functional example of how multipart MIME actually works in practice. With both of my hands in the carburetor (a car repair term for getting down to business and having things done fast) I sit down and get busy with creating the necessary [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.nedkoko.com/blog/images/code.jpg" align="left" border="1" height="196" hspace="5" vspace="5" width="200" /> Let&#8217;s see how we can use some simple tools and create a functional example of how multipart MIME actually works in practice. With both of my hands in the carburetor (a car repair term for getting down to business and having things done fast) I sit down and get busy with creating the necessary form and php script. Before I get into more details I want to make clear that you will need PHP set up correctly. For the purposes of creating something interactive we&#8217;ll use our code in the context of an Apache 2 web server which will make testing and using the application easier. <span id="more-10"></span><br />
<strong><br />
Prerequisites:</strong></p>
<p>To get everything started we&#8217;ll prepare a web form in pure XHTML which submits the content entered by the user via POST submit to our script which will assemble the message and send it. Our script will utilize the <a href="http://us3.php.net/function.mail" target="_blank">PHP mail function</a> so you will have that functionality enabled on your server in order to send email messages. In PHP this configuration is done in <code>php.ini</code>  in a section called <code>[mail function]</code>. I am not going to get into great details but in short there will be three settings : <code>SMTP</code>, <code>sendmail_from</code>, and <code>sendmail_path</code> that you will have to configure. If you are configuring a Windows machine you would want to set the <code>SMTP</code> section to your outgoing SMTP server whereas UNIX and Linux users will have to set  <code>sendmail_path</code> to make use of the <code>sendmail</code> program unless you don&#8217;t have <code>sendmail</code> installed or will prefer use SMTP anyway. In either case sendmail_from will refer to the email address that will appear as the default in the <code>from</code> section.<br />
<strong><br />
Getting Started:</strong></p>
<p>In order to make it easier for the user to create messages from scratch we&#8217;ll provide an XHTML form with the following fields: email (that will be the sender&#8217;s email), subject, text content, and html content. Alternatively you can provide a field for the recipient(s) email but for spam purposes our public form will not utilize that. You can easily refactor it and provide that functionality by adding a single field.<br />
<code><br />
&lt;input name="email" size="20" type="text" /&gt;<br />
&lt;input name="subject" size="20" type="text" /&gt;<br />
&lt;textarea cols="40" rows="10" name="messageplain"&gt;&lt;/textarea&gt;<br />
&lt;textarea cols=40 rows=10 name="messagehtml"&gt;&lt;/textarea&gt;<br />
</code><br />
Here is the full <a href="http://www.nedkoko.com/blog/images/email/form.html">XHTML page with the form</a>. Please ignore the plain styling &#8211; you can easily override the CSS and create some fancy styling. I will strongly suggest if doing that to get everything working first.<br />
As you can see our form element uses the POST method and submits to the next part of our discussion: the <code>mail.php</code> document containing our message assembly and submission code<br />
<code>&lt;form action="mail.php" method="POST"&gt;</code></p>
<p>Now let&#8217;s look closer at what happens behind the scenes and how our message gets processed. To be able to successfully accomplish our goal we need to examine the anatomy of an email message. An email consists of three components:</p>
<ul>
<li><strong>the envelope</strong> &#8211; includes routing information for your message and is used by the MTA to transfer your email over the network. Typically you don&#8217;t need to be concerned with the envelope as it is not visible by the user.</li>
<li><strong>the headers</strong> &#8211; the headers are the most intererting part of an email containing processing information. Some are mandatory: Date From, To, (or BCC) while others are optional: Subject, Cc, Reply-To, Received, Message-Id.</li>
<li><strong>the message body</strong> &#8211; this is the section with the actual content of your email message. The body is separated from the headers by a single blank line.</li>
</ul>
<p>First we need to create our mail headers correctly. Let&#8217;s look at an example of what our headers need to look like:<em><code></code></em></p>
<p><em>From: &lt;admin@nedkoko.com&gt;<br />
To: &lt;recipient@domain.com&gt;<br />
MIME-Version: 1.0<br />
Content-Type: multipart/alternative;  boundary=&#8221;fU3W4Vzr4G3D54f3&#8243;</em></p>
<p>Keep in mind that this is a simplified version of the headers but it works great for the purposes of our demonstration. Note that for content type &#8220;multipart/mixed&#8221; is used to send messages with different Content-Type sections (usually attachments) but for our purposes we want to use &#8220;multipart/alternative&#8221; which signifies different (&#8220;alternative&#8221;) versions of the same content.<br />
Ok, now that we know what our headers need to look like we can start our form processing by extracting the content from our submission:<em><code></code></em></p>
<p><em><code>$email = $_POST['email'];<br />
$to = 'nedko1@yahoo.com';<br />
$subject = $_POST['subject'];<br />
$messageplain = $_POST['messageplain'];<br />
$messagehtml = $_POST['messagehtml'];</code></em></p>
<p>Now that we have our form content we need to create our boundary for separating the different parts of the message. A good way to do that is to use some kind of hashing which will guarantee uniqueness and will be different for each message. For that purpose i decided to use and MD5 hash algorithm applied on the current timestamp. That will satisfy our requirements and provide a 128bit value we can use for separation.<br />
<code>$mime_boundary = "----=_NextPart_X[".md5(time())."]";</code>.<br />
Let&#8217;s proceed next with creating a nice little header based on what we have so far:<br />
<code><br />
$headers = "From: &lt;admin@nedkoko.com&gt;\r\n".<br />
"To: &lt;".$to."&gt; \r\n".<br />
"MIME-Version: 1.0\r\n" .<br />
"Content-Type: multipart/alternative; ".<br />
"boundary=\"".$mime_boundary."\"\r\n";<br />
</code><br />
As you notice the &#8220;boundary&#8221; is not a separate header as it&#8217;s not separated on a new line as the specs require. That is because it is considered as a part of the &#8220;Content-Type&#8221;. It&#8217;s time to pay more attention to our actual message which will follow our headers separated by a blank line. Since we have multiple sections of our message body we will start each section with &#8220;&#8211;&#8221; followed by the boundary, followed by the content type and encoding. As we have two sections: text and HTML versions we start with the text:<em><code></code></em></p>
<p><em>&#8220;&#8211;&#8221;.$mime_boundary.&#8221;\r\n&#8221;.<br />
&#8220;Content-Type: text/plain; charset=\&#8221;utf-8\&#8221;\r\n&#8221;.<br />
&#8220;Content-Transfer-Encoding: quoted-printable\r\n\r\n&#8221;.<br />
$messageplain.&#8221;\r\n\r\n&#8221;.</em></p>
<p>Then we do the same with the HTML version. Again we provide &#8220;&#8211;&#8221; with the boundary, content type and then the encoding:<br />
<em><code><br />
"--".$mime_boundary."\r\n".<br />
"Content-Type: text/html; charset=\"utf-8\"\r\n".<br />
"Content-Transfer-Encoding: 8bit\r\n\r\n".<br />
$messagehtml."\r\n\r\n".</code></em></p>
<p>Looks like we are finished with both versions of the message so now we have to wrap it up and specify that this is the end of our body content:<br />
<code><br />
<em>"--".$mime_boundary."--\r\n";</em></code></p>
<p>Note that the end is demarcated by &#8220;&#8211;&#8221; both in front and after the boundary, making if different from separator between different parts of the body. Finally, we can apply some basic form validation (optional but recommended) and call the mail function to process our mail request. It is important to mention that the mail function can be invoked with <code>@</code> in order to suppress any errors it generates. Even better it returns a boolean value specifying if the message was successfully sent so we can then include some extra logic to provide feedback to the user.<br />
<em><code><br />
if (mail($to,$subject,$message, $headers))<br />
{<br />
echo "&lt;h4&gt;Your message was sent successfully. &lt;/h4&gt;";<br />
}</code></em></p>
<p>Mission accomplished! Here you can download a <a href="http://www.nedkoko.com/blog/images/email/mail.zip">zip of the full mail.php</a> as well as <a href="http://www.nedkoko.com/blog/images/email/form.html">see the full working version in action here</a>. Hope this quick introduction has shed more light into email message formats and specifics of MIME.</p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.nedkoko.com%2Fblog%2Fdevelopment%2Fmultipart-mime-email-example-in-php&amp;linkname=Multipart%20MIME%20email%20example%20in%20PHP"><img src="http://www.nedkoko.com/wp/wp-content/plugins/add-to-any/share_save_256_24.png" width="256" height="24" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.nedkoko.com/blog/development/multipart-mime-email-example-in-php/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Sending HTML and plain text emails simultaneously &#8211; multipart solution</title>
		<link>http://www.nedkoko.com/blog/development/sending-html-and-plain-text-emails-simultaneously-multipart-solution-used-in-email-marketing</link>
		<comments>http://www.nedkoko.com/blog/development/sending-html-and-plain-text-emails-simultaneously-multipart-solution-used-in-email-marketing#comments</comments>
		<pubDate>Mon, 19 Nov 2007 04:14:38 +0000</pubDate>
		<dc:creator>Nedko</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://www.nedkoko.com/blog/2007/11/19/sending-html-and-plain-text-emails-simultaneously-multipart-solution-used-in-email-marketing/</guid>
		<description><![CDATA[Background
I cannot quite recall the first time I sent an email except that for all I know it  was a long time ago and that it&#8217;s only intent was to notify its recipient that I had actually embraced the cyberspace. It was a time when having an email address was a privilege, not a [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Background</strong></p>
<p><img src="http://www.nedkoko.com/blog/images/email.jpg" title="email" alt="email" align="left" height="190" hspace="5" width="190" />I cannot quite recall the first time I sent an email except that for all I know it  was a long time ago and that it&#8217;s only intent was to notify its recipient that I had actually embraced the cyberspace. It was a time when having an email address was a privilege, not a right and 1200bps modems where top of the line. In today&#8217;s world I would be quite astonished if somebody told me they don&#8217;t have an email. In fact I will be even more surprised if they told me that they have an email which they don&#8217;t use on a daily basis to conduct personal and business activities but merely for the purpose of having one.</p>
<p>Today as email becomes more popular than traditional mail we send plain text emails, HTML emails and even rich media emails containing Flash. While the good old plaint text emails were easily readable they were ugly to say the least and not quite well organized as far as data presentation is concenred. With all the advantages that HTML layout and presantation brings to the table come some caveats: even if we assume that all your recepients will be able to see the content (if they have HTML enabled) we can&#8217;t be quite sure how it will look on different mail clients due to a number of reasons. The solution: Multipart emails. <span id="more-9"></span></p>
<p><strong>What is the Multipart MIME?</strong></p>
<p>The Multipart mime content is just another fancy term for providing more than one version of your email. In reality MIME stands for Multipurpose Internet Mail Extensions and was created as a standard to extend the existing one and provide support for [you guessed it] among other things support for multipart message body, non-text attachment and non-ASCII (e.g. UTF8) character encondings.  The way multipart content works is by specifying a boundary in the &#8220;Content-type:&#8221; header of your email. The boundary is used to separate the different content types and looks something like this:</p>
<pre>Content-type: multipart/mixed; boundary="fU3W4Vzr4G3D54f3"</pre>
<pre></pre>
<p>There are no rules as of the content of the boundary but as it must not occur in any of the parts of your message content is usually a randomly generated sequence of numbers, letters or combination of both in order to guarantee uniqueness and differentiate from any possible dictionary words. So as you start your message each data type section is separated by &#8220;&#8211;&#8221; followed by the boundary sequence and the content type + encoding. After the last section &#8220;&#8211;&#8221; followed by the boundary followed by &#8220;&#8211;&#8221; is used to delimit the end of the message. Here is an example of a complete message:</p>
<pre>MIME-version: 1.0
Content-type: multipart/mixed; boundary="fU3W4Vzr4G3D54f3"

This is a multi-part message in MIME format.
--fU3W4Vzr4G3D54f3</pre>
<pre>Content-type: text/plain; charset="utf-8"
Content-Transfer-Encoding: quoted-printable
This is the body of the message.
--fU3W4Vzr4G3D54f3</pre>
<pre>Content-type: text/html; charset="utf-8"
Content-Transfer-Encoding: 8bit</pre>
<pre>&lt;html&gt;
  &lt;head&gt;&lt;title&gt;A HTML email&lt;/title&gt;&lt;/head&gt;
  &lt;body&gt;This is the body of the message.&lt;/body&gt;
&lt;/html&gt;</pre>
<pre>--fU3W4Vzr4G3D54f3--</pre>
<p>Note that for demonstration purposes we&#8217;ve oversimplified the HTML. In a real environment you would want to be as explicit as possible and provide a doctype for your HTML document as well as follow the guidelines as much as possible to ensure uniform rendering across engines.</p>
<p><strong>Some useful tips</strong></p>
<p>So far so good! Now that we are familiar with how the multiheader MIME emails can help you ensure that your message will reach its intended audience we need to spend some time and pay attention to some specifics of formatting.</p>
<ul>
<li>Keep it simple &#8211; concentrate on your content rather than sophisticated presentation. Focus on your message! As far has the HTML is concerned &#8211; don&#8217;t get too fancy and code a very simple, old school webpage.</li>
<li>I can&#8217;t stress enough how important HTML formatting is but I want to reiterate that you need to be very careful and make sure to create valid, well formatted HTML. To ensure the quality of your code and the proper rendering I will suggest that you use a professional tool like Dreamweaver of Frontpage or an online <a href="http://validator.w3.org/" target="_blank">validator</a> as the one from the <a href="http://www.w3.org/" target="_blank">W3C</a>. Of course in addition to that I will suggest testing the rendering in different browsers and email clients to avoid surprises.</li>
<li>Along the same lines you will need to set an online version of the HTML document and include a link with the URL in the beginning of both the plaintext and HTML versions. This will ensure that your recipient can open the message in a browser if there are any rendering problems, the content is blocked by a spam engine or if the plaintext version is just not good enough. This comes quite useful as usually the purpose of your message is to get the recipient to visit the website and start some sort of interaction.</li>
<li>Use tricks like capitalizing the headlines and spacing or underlining for distinguishable headlines and section separation. This can be very helpful for plaintext emails as they can often be hard to read.</li>
<li>As usually spam blockers often prevent some of the images from displaying be careful and don&#8217;t overuse images for messages. For all images provide good &#8216;alt&#8217; attribute description for the content of the image in the cases when they are not shown.</li>
<li>Webmail based services are more than likely going to slightly modify your code so be prepared to have tags like DOCTYPE, BODY, and HEAD to be stripped. That&#8217;s expected as understandably those elements have the chance to interfere with their site.</li>
<li>Avoid sophisticated designs requiring high width as a lot of the client email preview windows will be just a few hundred pixels wide.</li>
<li>Don&#8217;t rely on heavy use of CSS styles as almost 90% of the time they will get stripped. That&#8217;s especially true for services like Hotmail, Yahoo Mail, and Gmail as your CSS has a chance to override their own styles.</li>
<li>Tables are your friend. Really! Use TABLE tags to position the content within your web page. Go back to basics and rely on what&#8217;s proven and working across different rendering engines.</li>
<li>Work with a carefully selected vocabulary. That&#8217;s especially true for words you include in the title as they are very likely to stand out when examined by the spam filters.</li>
<li>Keep your message short. Remember that multiplart MIME emails technically double the length of your email so while they work great for relatively short emails</li>
<li>Test, Test, Test &#8211; That&#8217;s really the safest way to make sure that there won&#8217;t be surprises. Apart from not accomplishing your goal you are running the risk to loose credibility with your audience.</li>
</ul>
<p><strong>NEXT: </strong>see an example on how to create a multipart MIME email web form in PHP (&#8230;coming soon)</p>
<p><strong>Resources:</strong></p>
<p><a href="http://en.wikipedia.org/wiki/MIME">Mime</a><br />
<a href="http://www.wilsonweb.com/wmt5/html-email-multi.htm" target="_blank">Sending both HTML and plain text emails<br />
</a><a href="http://tools.ietf.org/html/rfc2045" target="_blank">RFC2045</a>, <a href="http://tools.ietf.org/html/rfc2046" target="_blank">RFC2046</a>, <a href="http://tools.ietf.org/html/rfc2047" target="_blank">RFC2047</a>, <a href="http://tools.ietf.org/html/rfc4288">RFC4288</a>, <a href="http://tools.ietf.org/html/rfc4289" target="_blank">RFC4289</a>, <a href="http://tools.ietf.org/html/rfc2077" target="_blank">RFC2077</a></p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.nedkoko.com%2Fblog%2Fdevelopment%2Fsending-html-and-plain-text-emails-simultaneously-multipart-solution-used-in-email-marketing&amp;linkname=Sending%20HTML%20and%20plain%20text%20emails%20simultaneously%20%26%238211%3B%20multipart%20solution"><img src="http://www.nedkoko.com/wp/wp-content/plugins/add-to-any/share_save_256_24.png" width="256" height="24" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.nedkoko.com/blog/development/sending-html-and-plain-text-emails-simultaneously-multipart-solution-used-in-email-marketing/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Space Shuttle</title>
		<link>http://www.nedkoko.com/blog/general/the-space-shuttle</link>
		<comments>http://www.nedkoko.com/blog/general/the-space-shuttle#comments</comments>
		<pubDate>Tue, 23 Oct 2007 19:58:07 +0000</pubDate>
		<dc:creator>Nedko</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://www.nedkoko.com/blog/2007/10/23/the-space-shuttle/</guid>
		<description><![CDATA[ It has beaten many world records including the fastest, loudest, The Space Shuttle &#8211; the most sophisticated piece of machinery ever built by man. Although for almost everybody the space shuttle or also known as by it&#8217;s official name Space Transportation System (STS) needs no introduction we can briefly describe the most notable facts [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.nedkoko.com/blog/images/shuttle/shuttle-main-platform.jpg" align="left" border="1" height="259" hspace="7" width="330" /> It has beaten many world records including the fastest, loudest, The Space Shuttle &#8211; the most sophisticated piece of machinery ever built by man. Although for almost everybody the space shuttle or also known as by it&#8217;s official name Space Transportation System (STS) needs no introduction we can briefly describe the most notable facts about it.</p>
<p>The Space Shuttle is used by the US government for human spaceflight missions and is designed with the goal to carry astronaut and load such as satellites and modules to the International Space Station. It was first launched on April 12, 1981 and is still in use to present day. Originally six shuttles were built but as the Enterprise was not designed for flight only five were deemed spaceworthy. As Challenger and Columbia were destroyed in takeoff and reentry disasters only 3 currently remain: Discovery, Atlantis and Endeavour. More information about the space shuttle and it&#8217;s structure you can find <a href="http://www.nasa.gov/mission_pages/shuttle/vehicle/index.html" target="_blank">here</a>. <span id="more-8"></span></p>
<p><img src="http://www.nedkoko.com/blog/images/shuttle/strapped.jpg" title="strapped in space shuttle" alt="strapped in space shuttle" align="right" border="1" height="223" hspace="7" width="330" />Apart from being just a vehicle the shuttle program is a medium in establishing world peace and cooperation.Long gone are the days when space was considered solely expressions of patriotism and competition in the arms race in the Cold War. The shuttle is the main vehicle for transporting modules and equipment from and to the space station. Today the International Space Station (ISS) is the biggest space laboratory known to man and hosts technology and personnel from all over the world. And with STS 120 a new record is set &#8211; for the first time in history of space exploration two women are in charge of two spacecrafts at the same time as Pamela Melroy is calling the shots on Discovery and ISS commander Peggy Whitson.</p>
<p><img src="http://www.nedkoko.com/blog/images/shuttle/sts120-launch.jpg" title="STS-120 launch" alt="STS-120 launch" align="left" border="1" height="389" hspace="7" width="330" />But as high tech as it is some of the design and technology used for the original construction is aged and obsolete and therefore often compared to an old car. Due to safety concerns and a way to provide a honorable retreat for the shuttle NASA has decided to move on. Unfortunately the time and resources needed to maintain and keep up to date with technology are overwhelming and the point was reached to where it&#8217;s not worth it.  While NASA has announced the retiring of the Shuttle program in 2010 which will be replaced by 2014 by <a href="http://en.wikipedia.org/wiki/Orion_%28spacecraft%29" target="_blank">Orion</a> a new age in space exploration is marked. Partly with pride and honor and partly with sadness humanity gets ready for a shift. Not simply a shift of technology but a shift of evolution and creativity of mankind. To honor those who believed, those who dedicated their life and those who lost it I would consider attending a space shuttle launch as one of my top 10 on the TO DO list.</p>
<p><img src="http://www.nedkoko.com/blog/images/shuttle/cockpit.jpg" title="Space shuttle cockpit" alt="Space shuttle cockpit" align="left" border="1" height="457" width="608" /></p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.nedkoko.com%2Fblog%2Fgeneral%2Fthe-space-shuttle&amp;linkname=The%20Space%20Shuttle"><img src="http://www.nedkoko.com/wp/wp-content/plugins/add-to-any/share_save_256_24.png" width="256" height="24" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.nedkoko.com/blog/general/the-space-shuttle/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How TO: Boost your blog traffic</title>
		<link>http://www.nedkoko.com/blog/how-tos/how-to-boost-your-blog-traffic</link>
		<comments>http://www.nedkoko.com/blog/how-tos/how-to-boost-your-blog-traffic#comments</comments>
		<pubDate>Thu, 18 Oct 2007 19:58:55 +0000</pubDate>
		<dc:creator>Nedko</dc:creator>
				<category><![CDATA[HOW TOs]]></category>

		<guid isPermaLink="false">http://www.nedkoko.com/blog/2007/10/18/how-to-boost-your-blog-traffic/</guid>
		<description><![CDATA[Want to increase the traffic to your blog and get more visitors? You&#8217;ve come to the right place. Read on and find out the fastest ways to improve the quality and drive traffic. Most beginners assume that once they start their blog they are done and all they have to do is sit down, relax [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.nedkoko.com/blog/images/graph.jpg" title="web traffic graph" alt="web traffic graph" align="left" border="1" height="206" hspace="5" vspace="5" width="200" />Want to increase the traffic to your blog and get more visitors? You&#8217;ve come to the right place. Read on and find out the fastest ways to improve the quality and drive traffic. Most beginners assume that once they start their blog they are done and all they have to do is sit down, relax and watch their traffic go up. Unfortunately they are wrong <span id="more-7"></span></p>
<p><strong>Style and Design &#8211; be attractive</strong></p>
<p>This is the start of any successful and even decent blog. In order to attract visitors and eventually regular readers you will need to start with the basics &#8211; the building blocks. Regardless of whether you have a custom solution or a hosted blog somewhere it is really important early on in the game to start with clean, organized, and well styled blog which is easy to read. This first step will improve the usability and will help boost your credibility as a content provider. To read more on <a href="http://www.usability.gov/">usability</a> visit <a href="http://www.useit.com/" target="_blank">Jacob Nielsen&#8217;s website</a>. Furthermore you can use one of the thousands of <a href="http://blogger-templates.blogspot.com/" target="_blank">ready templates</a> available online or create your own.</p>
<p><strong>Content &#8211; it&#8217;s all about what you have to offer<br />
</strong></p>
<p>In order to best serve your visitors you need to provide the right content. One way is to target specific audience by providing specialized information. That will be your niche and most of your readers will be return visitors interested in that topic. Another approach will be to provide original content or opinions on something widely publicized. When providing content make sure you are not &#8216;borrowing&#8217; somebody else&#8217;s thought and ideas. Here is a list of the <a href="http://www.dailyblogtips.com/copyright-law-12-dos-and-donts/">12 DOs and DON&#8217;Ts</a> with regards to copyright.</p>
<p><strong>Know your audience &#8211; the customer is king<br />
</strong></p>
<p>In order to be a successful blogger you will need to possess qualities like dedication, passion and endurance. Remember that blogging is not a sprint but a marathon and only the fittest survive. Therefore getting familiar with your traffic is your responsibility. Start by using some of the available tools to obtain data and measure key statistics about the people visiting your blog. Who are your visitors? Where do they come from? How do they find your content? What do they read and how long? How many repeating visitors you have? Answering questions like these can be crucial to being successful. A simple example will be knowing how many people are subscribed to your RSS feeds. In order to obtain traffic data use one of the numerous tools like <a href="http://www.google.com/analytics" target="_blank">Google Analytics</a>, <a href="http://www.feedburner.com/" target="_blank">Feed Burner</a> or your web server stats (<a href="http://awstats.sourceforge.net/" target="_blank">here is a tool for Apache</a>)</p>
<p><strong>Arm Yourself &#8211; use all the tools at your convenience</strong></p>
<p>Use the tools that will help you improve your site and make it easily accessible. For a starter you can make your blog URLs more user and search engine friendly by using permalinks. This makes your pages easier to remember, bookmark, and find by search engine. Here is a short <a href="http://codex.wordpress.org/Using_Permalinks" target="_blank">permalinks guide</a> for WordPress. Another great think that you can use to your advantage is to provide RSS feeds of your blog. This can be done either independently or linked through <a href="http://www.feedburner.com" target="_blank">Feed Burner</a> for advanced capabilities and tracking purposes. For added value or &#8220;bonus points&#8221; so to say it will be nice to include podcasts and/or videos to your blog. And if you still have not had enough you can include to your blog the rest of the bells and whistles out there &#8211; <a href="http://no.oneslistening.com/160" target="_blank">featured article</a> plugins, social bookmarking tools like links to del.icio.us, Digg etc. You can also take the initiative and post your blog on any of those sites and even more (<a href="http://blogsoftheday.com/" target="_blank">BlogsOfTheDay</a>, <a href="http://www.technorati.com/" target="_blank">Technorati</a> and others).</p>
<p><strong>In Conclusion&#8230;</strong></p>
<p>In conclusion I want to re-iterate by saying that i can&#8217;t possibly stress enough how important following the rules above is to your final success. As simple as those basic directions might seem they are very often ignored or followed wrong. Remember: create a welcoming blog, be original and creative, don&#8217;t steal other people&#8217;s content, get to know your audience, use all the tools that can possibly help you attract more readers. Make sure you keep the two-way communication with your readers by providing feedback to their comments and repsonding to emails. Feels free to add more to the topic by posting comments below. Happy Blogging!</p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fwww.nedkoko.com%2Fblog%2Fhow-tos%2Fhow-to-boost-your-blog-traffic&amp;linkname=How%20TO%3A%20Boost%20your%20blog%20traffic"><img src="http://www.nedkoko.com/wp/wp-content/plugins/add-to-any/share_save_256_24.png" width="256" height="24" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://www.nedkoko.com/blog/how-tos/how-to-boost-your-blog-traffic/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
