<?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>Ionut Staicu - Webdeveloper Blog &#187; Advices</title>
	<atom:link href="http://dev.iamntz.com/category/advices/feed" rel="self" type="application/rss+xml" />
	<link>http://dev.iamntz.com</link>
	<description>Stuff about CSS, XHTML, Javascript and jQuery</description>
	<lastBuildDate>Thu, 26 May 2011 05:43:45 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<item>
		<title>Do you still offer support for IE6?</title>
		<link>http://dev.iamntz.com/212/do-you-still-offer-support-for-ie6</link>
		<comments>http://dev.iamntz.com/212/do-you-still-offer-support-for-ie6#comments</comments>
		<pubDate>Wed, 17 Jun 2009 19:48:03 +0000</pubDate>
		<dc:creator>Staicu IonuÈ›-Bogdan</dc:creator>
				<category><![CDATA[Advices]]></category>
		<category><![CDATA[Debates]]></category>

		<guid isPermaLink="false">http://dev.iamntz.com/?p=212</guid>
		<description><![CDATA[If the answer is &#8220;yes&#8221;, may I know&#8230; WHY? I mean c&#8217;mon, we have now three versions of IE, one of them is almost 10 years old (yeah, i know, 8 is more exact number) and is filled with bugs &#8230; <a href="http://dev.iamntz.com/212/do-you-still-offer-support-for-ie6">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>If the answer is &#8220;yes&#8221;, may I know&#8230; WHY? I mean c&#8217;mon, we have now three versions of IE, one of them is almost 10 years old (yeah, i know, 8 is more exact number) and is filled with bugs and flaws. You don&#8217;t have advanced selectors, you don&#8217;t have png support (actually you have, but is very rudimentary), javascript is slower and so on.</p>
<p>Maybe you&#8217;ll say that IE6 is still used by aprox 15% of users. That is <a href="http://www.w3schools.com/browsers/browsers_stats.asp">correct</a>, but think at this aspect: an average user has no idea how awful his browser is. Because we &#8211; the front end developers &#8211; we struggle to make site 100% compatible with IE6. Ok, no user will upgrade their browser for *your* site, right? Partially correct. Let me show you why: If the user can&#8217;t use your site, i&#8217;m 99% sure that he will *not* update his browser and will leave. Unless will find several sites that won&#8217;t work on his &#8220;great&#8221; browser, right?</p>
<p>To demonstrate the user ignorance (ignorance is bliss, right?), take a look at what average user answer on a very simple question: &#8220;what is a browser?&#8221;</p>
<p><object width="640" height="385"><param name="movie" value="http://www.youtube.com/v/o4MwTvtyrUQ&#038;hl=en&#038;fs=1&#038;rel=0&#038;color1=0x5d1719&#038;color2=0xcd311b"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/o4MwTvtyrUQ&#038;hl=en&#038;fs=1&#038;rel=0&#038;color1=0x5d1719&#038;color2=0xcd311b" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="640" height="385"></embed></object></p>
<p>I personally offer IE6 support only for some extra cash (+25%). Some clients are OK, some are not.</p>
<p>So.. Do you still support IE6?</p>
]]></content:encoded>
			<wfw:commentRss>http://dev.iamntz.com/212/do-you-still-offer-support-for-ie6/feed</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Dell 2408 service menu</title>
		<link>http://dev.iamntz.com/199/dell-2408-service-menu</link>
		<comments>http://dev.iamntz.com/199/dell-2408-service-menu#comments</comments>
		<pubDate>Sun, 24 May 2009 17:05:11 +0000</pubDate>
		<dc:creator>Staicu IonuÈ›-Bogdan</dc:creator>
				<category><![CDATA[Advices]]></category>

		<guid isPermaLink="false">http://dev.iamntz.com/?p=199</guid>
		<description><![CDATA[This is not web related in any way, but after almost a year with this monitor, I found out how to get into service menu: Turn off the monitor Hold the `menu` key and `+` key pressed and turn the &#8230; <a href="http://dev.iamntz.com/199/dell-2408-service-menu">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>This is not web related in any way, but after almost a year with this monitor, I found out how to get into service menu:</p>
<ul>
<li>Turn off the monitor</li>
<li>Hold the `menu` key and `+` key pressed and turn the &#8216;monster&#8217; back on</li>
<li>After it&#8217;s on, release all buttons then press `-` key. A huge menu will be displayed in top left corner</li>
</ul>
<p>Ok, so? What can you do with this? You can set some stuff that you usually can&#8217;t. Do this on your own risk <img src='http://dev.iamntz.com/wp-includes/images/smilies/biggrin.gif' alt=':D' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://dev.iamntz.com/199/dell-2408-service-menu/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Recovering after a crash of e-texteditor</title>
		<link>http://dev.iamntz.com/151/recovering-after-a-crash-of-e-texteditor</link>
		<comments>http://dev.iamntz.com/151/recovering-after-a-crash-of-e-texteditor#comments</comments>
		<pubDate>Mon, 02 Feb 2009 18:23:14 +0000</pubDate>
		<dc:creator>Staicu IonuÈ›-Bogdan</dc:creator>
				<category><![CDATA[Advices]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Editors]]></category>

		<guid isPermaLink="false">http://dev.iamntz.com/?p=151</guid>
		<description><![CDATA[Even the best software have troubles sometimes. Today i will show you how to survive after a crash of E-texteditor (i survived twice so, you can do too ). For various reasons, E-text can crash or just hang when you &#8230; <a href="http://dev.iamntz.com/151/recovering-after-a-crash-of-e-texteditor">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Even the best software have troubles sometimes. Today i will show you how to survive after a crash of E-texteditor (i survived twice so, you can do too <img src='http://dev.iamntz.com/wp-includes/images/smilies/tongue.gif' alt=':P' class='wp-smiley' />  ).</p>
<p>For various reasons, E-text can crash or just hang when you want to save (especially when you work remotely, via FTP) and can ruin the work of a whole day (or even more) because when saves, the editor will first empty/remove current file, then will write the new one. And if the editor crash just after file is removed, you are screwed. Or, at least, you think so.</p>
<p>Whan you need to do: </p>
<p>Grab a small and fast editor. My pick is <a href="http://www.scintilla.org/SciTEDownload.html">Scite</a>. Is small and is DAMN fast with huge files.</p>
<p>Hit your WIN+R on your keyboard and write this: <code>%appdata%\e\temp</code>. Then dragg all files in Scite. Here you can find all recently edited files (may be many files, on my pc there is around 30 or so). Now, all you need to do is to find the file you was saving when the editor crashed. I know, it may be hard, but i can bet is not harder than rewritting your whole file <img src='http://dev.iamntz.com/wp-includes/images/smilies/wink.gif' alt=';)' class='wp-smiley' /> </p>
<h3>Bonus tip:</h3>
<p>Older version of E-texteditor was somehow unstable in various circumstances. And because i use E since 1.0 or so, i had to develop a good habit: backup my settings. For doing that i use <a href="http://www.microsoft.com/DownLoads/details.aspx?familyid=C26EFA36-98E0-4EE9-A7C5-98D0592D8C52&#038;displaylang=en">Sync Toy 2</a>. Every night<strong> i close my editor</strong> and every morning synctoy will copy my settings on another partition, just in case. It&#8217;s VERY important to close the editor before backup, because most settings (like ftp accounts) are saved when editor closes. So, unless you want your backup to be useless, please, close your editor <img src='http://dev.iamntz.com/wp-includes/images/smilies/biggrin.gif' alt=':D' class='wp-smiley' /> </p>
<h3>Bonus tip 2:</h3>
<p>From time to time, visit <a href="http://www.e-texteditor.com/forum/viewforum.php?f=7">e-texteditor forums</a>. Most new versions don&#8217;t hit the front page if they are not well tested. Live example: on homepage, the last version is 1.0.30 and on forums is 1.0.31 (which is way more stable). So.. Keep an eye there!</p>
]]></content:encoded>
			<wfw:commentRss>http://dev.iamntz.com/151/recovering-after-a-crash-of-e-texteditor/feed</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Get organized!</title>
		<link>http://dev.iamntz.com/128/get-organized</link>
		<comments>http://dev.iamntz.com/128/get-organized#comments</comments>
		<pubDate>Thu, 11 Dec 2008 11:54:01 +0000</pubDate>
		<dc:creator>Staicu IonuÈ›-Bogdan</dc:creator>
				<category><![CDATA[Advices]]></category>
		<category><![CDATA[How is made?]]></category>

		<guid isPermaLink="false">http://dev.iamntz.com/?p=128</guid>
		<description><![CDATA[Here is a very nice trick that you can use to make your own subdomains on&#8230; localhost. I know, it sound difficult as hell but, in fact, it&#8217;s easy as hell In this mini-tutorial i assume that you use Xampp, &#8230; <a href="http://dev.iamntz.com/128/get-organized">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Here is a very nice trick that you can use to make your own subdomains on&#8230; localhost. I know, it sound difficult as hell but, in fact, it&#8217;s easy as hell <img src='http://dev.iamntz.com/wp-includes/images/smilies/biggrin.gif' alt=':D' class='wp-smiley' /> </p>
<p>In this mini-tutorial i assume that you use <a href="http://www.apachefriends.org/en/xampp.html">Xampp</a>, but you can use with any other *AMP configuration, on any platform (Windows, Mac, Linux, whatever). Also, because i don&#8217;t own a static IP (my ISP is &#8220;kind&#8221; enough to change my IP every single time when i power up my PC), i use a <a href="http://dynamicnetworkservices.com/">dynamic DNS service</a>. Ofcourse, you are not restrained to use this service, you can find plenty of similar sites, but i use this and i&#8217;m happy with it <img src='http://dev.iamntz.com/wp-includes/images/smilies/tongue.gif' alt=':P' class='wp-smiley' /> </p>
<p>Anyhow, let&#8217;s begin.</p>
<p><strong>Step 1. Edit httpd.conf</strong></p>
<p>If you use Xampp, and you installed with default settings, you will find httpd.conf in <code>C:\xampp\apache\conf</code>. On httpd.conf you need to find <code>Include conf/extra/httpd-vhosts.conf</code>. If this line have a &#8220;#&#8221; char, just remove.</p>
<p><strong>Step 2. Edit <code>conf/extra/httpd-vhosts.conf</code>.</strong></p>
<p>This is the fun part. Just add at the end of the file this lines:</p>
<pre lang="html">
<VirtualHost *:80>
	DocumentRoot G:/htdocs/mysubdomain
	ServerName mysubdomain.my_domain.selfip.com
</VirtualHost>
</pre>
<p>Then save and restart your apache server. Guess what? Now you have a subdomain! </p>
<p><strong>Step 3. Assets folder</strong></p>
<p>In a previous article<a href="http://dev.iamntz.com/76/one-development-trick"> i showed you</a> how to put all libraries in same folder to avoid too many folder. Of course, this is fine when you don&#8217;t use subdomains. But what to do when you use? Well.. You edit <code>httpd.conf</code> !</p>
<p>First of all you need to be sure that <a href="http://httpd.apache.org/docs/2.2/mod/mod_alias.html">Mod_alias</a>.so is loaded. Find LoadModule <code>alias_module modules/mod_alias.so</code> and be sure it doesn&#8217;t have any &#8220;#&#8221; in front. Then add this at the end of the document:</p>
<p><code>AliasMatch ^/assets(.*) G:/htdocs/assets$1</code></p>
<p>Don&#8217;t forget to save and restart your server. </p>
<p>Next step is&#8230; There is no next step! You are ready to start/resume your regular work <img src='http://dev.iamntz.com/wp-includes/images/smilies/tongue.gif' alt=':P' class='wp-smiley' /> </p>
<p>Enjoy!</p>
]]></content:encoded>
			<wfw:commentRss>http://dev.iamntz.com/128/get-organized/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>How do you format your code?</title>
		<link>http://dev.iamntz.com/107/how-do-you-format-your-code</link>
		<comments>http://dev.iamntz.com/107/how-do-you-format-your-code#comments</comments>
		<pubDate>Fri, 28 Nov 2008 16:54:06 +0000</pubDate>
		<dc:creator>Staicu IonuÈ›-Bogdan</dc:creator>
				<category><![CDATA[Advices]]></category>
		<category><![CDATA[Tips & tricks]]></category>

		<guid isPermaLink="false">http://dev.iamntz.com/?p=107</guid>
		<description><![CDATA[I&#8217;ve been asked few times how do i format my code. I try to stick to a easy to read and understand style. Sometimes i do, sometimes i don&#8217;t. Let&#8217;s talk first about those times i do CSS Code Each &#8230; <a href="http://dev.iamntz.com/107/how-do-you-format-your-code">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been asked few times how do i format my code. I try to stick to a easy to read and understand style. Sometimes i do, sometimes i don&#8217;t. Let&#8217;s talk first about those times i do <img src='http://dev.iamntz.com/wp-includes/images/smilies/biggrin.gif' alt=':D' class='wp-smiley' /> </p>
<h1>CSS Code</h1>
<p>Each child is indented with a tab. So, i have this style:</p>
<pre lang="css" line="1">
#header {

}
	#search {

	}
		#search button {

		}
</pre>
<p>When you read only CSS you know that <code>#header</code> is the parent, <code>#search</code> is his child and the parent for <code>button</code>. Easy to read, easy to understand, right? <img src='http://dev.iamntz.com/wp-includes/images/smilies/tongue.gif' alt=':P' class='wp-smiley' /> </p>
<p>I try to avoid code like:</p>
<pre lang="css">
#parent #another_parent #header #search button { }
</pre>
<p>Because is kinda bogus.</p>
<p>I saw some guys who wrote their code on single line, without any indentation. Even if you have a less KB file, the result is hard to read and edit. Even though, i use very rarely one line code when i have to add one-two rule to a selector ( something like <code>.element { color:red } </code> ). </p>
<h1> HTML Code</h1>
<p>Actually&#8230; Somehow, i have same rule here: every child have a one tab indent:</p>
<pre lang="html" line="1">
<div id="header">
<form action="" method="get" class="search">
		<button type="submit">Button</button>
	</form>

<!--/.search-->
</div>

<!-- /header-->
</pre>
<p>As an extra info: when i have large blocks of code (div, forms), on closing tag i add a comment with the id or class name: if the block has a class, the closing comment is <code> /.class name</code> and if is an id <code> /id name </code></p>
<p>Again, easy to read and to maintain, especially when you reuse some of your code.</p>
<h1>Javascript/jQuery Code</h1>
<p>Well.. Probably is already clear enough how do i do:</p>
<pre lang="javascript" line="1">
function function_name() {
	var someVar = 1;
	if( someVar === 1 ) {
		alert('someVar is 1!');
		for(i=0;i<10;i++){
			alert(i);
		}
	} else {
		alert(':(');
	}
};//function_name
</pre>
<h1>Conclusion</h1>
<p>The main keywords are: <strong>indent</strong> and <strong>comments</strong>. You don't have to overuse indent, because the code will be impossible/hard to read. Also, don't over-comment your code. Don't comment the obvious :</p>
<pre lang="javascript">
var foo = 'bar'; // the 'foo' get 'bar' value
</pre>
<p>Well.. I can't say nothing else but „happy coding!”.</p>
]]></content:encoded>
			<wfw:commentRss>http://dev.iamntz.com/107/how-do-you-format-your-code/feed</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Which selector is faster?</title>
		<link>http://dev.iamntz.com/78/which-selector-is-faster</link>
		<comments>http://dev.iamntz.com/78/which-selector-is-faster#comments</comments>
		<pubDate>Mon, 29 Sep 2008 01:22:35 +0000</pubDate>
		<dc:creator>Staicu IonuÈ›-Bogdan</dc:creator>
				<category><![CDATA[Advices]]></category>

		<guid isPermaLink="false">http://dev.iamntz.com/?p=78</guid>
		<description><![CDATA[If you have any concerns about performance of your web application, you probably should read this. Some times ago i read on a site (don&#8217;t remember which, was like AGES ago) that a good performance improvement is to be VERY &#8230; <a href="http://dev.iamntz.com/78/which-selector-is-faster">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>If you have any concerns about performance of your web application, you probably should read this. Some times ago i read on a site (don&#8217;t remember which, was like AGES ago) that a good performance improvement is to be VERY specific when you use a library to select an element from the DOM. That article was written with Prototype in mind but i&#8217;ve though that will work same for jQuery as well. <strong>HUGE MISTAKE!</strong></p>
<p>Kinda obviously, jQuery is NOT Prototype and they seems to NOT work in the same manner. Today i think to test the results of various selector. For this, i used Profiler from Firebug (what? you don&#8217;t know what <a href="http://getfirebug.com">firebug</a> is?). And i was amazed. And i mean AMAZED!</p>
<p>I made this test right on this blog. I used <code>jQuery('li')</code> in console and, after that i used <code>jQuery('ul li')</code> (there is 24 LI elements on the first page). Until today i think the second option is faster. Why? Well.. Is more specific, isn&#8217;t it? </p>
<p>The second pick is around 2.6 times SLOWER than first one. (0.533ms vs 0.205ms).</p>
<p>Unfortunately, i&#8217;ve try to use the slower technique on many projects. But, lucky me, for no reason, i always forgot to do that (and i use to remember too late) <img src='http://dev.iamntz.com/wp-includes/images/smilies/biggrin.gif' alt=':D' class='wp-smiley' /> </p>
<p>So, be careful! Don&#8217;t make this mistake <img src='http://dev.iamntz.com/wp-includes/images/smilies/wink.gif' alt=';)' class='wp-smiley' />  If somebody will tell ya that a method is faster, DON&#8217;T take his word as a law. <strong>TEST IT!</strong></p>
]]></content:encoded>
			<wfw:commentRss>http://dev.iamntz.com/78/which-selector-is-faster/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>One development trick</title>
		<link>http://dev.iamntz.com/76/one-development-trick</link>
		<comments>http://dev.iamntz.com/76/one-development-trick#comments</comments>
		<pubDate>Sun, 28 Sep 2008 02:30:56 +0000</pubDate>
		<dc:creator>Staicu IonuÈ›-Bogdan</dc:creator>
				<category><![CDATA[Advices]]></category>
		<category><![CDATA[How is made?]]></category>

		<guid isPermaLink="false">http://dev.iamntz.com/?p=76</guid>
		<description><![CDATA[Actually&#8230; There is more than one Keep only one copy of your favorite javascript library (and also up to date!) I use jQuery a lot. No, actually i LOVE jQuery (is small, is fast, is easy to use, you know, &#8230; <a href="http://dev.iamntz.com/76/one-development-trick">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Actually&#8230; There is more than one <img src='http://dev.iamntz.com/wp-includes/images/smilies/biggrin.gif' alt=':D' class='wp-smiley' />  </p>
<h2>Keep only one copy of your favorite javascript library (and also up to date!)</h2>
<p>I use jQuery a lot. No, actually i LOVE jQuery (is small, is fast, is easy to use, you know, usual craps that make you to love it; just like a woman <img src='http://dev.iamntz.com/wp-includes/images/smilies/biggrin.gif' alt=':D' class='wp-smiley' />  ). To avoid duplicates of jquery, i use a folder called <strong>assets</strong> (but you can rename as you want as well). Here i keep latest version of jquery and jquery UI 1.5.2 (which now is the last stable version). With <a href="http://pages.interlog.com/~tcharron/wgetwin.html">wget</a> for windows in the assets folder, i wrote a small script to get latest version:</p>
<pre lang="bash">
del jquery-latest.min.js
wget http://code.jquery.com/jquery-latest.min.js
</pre>
<p>Put this in a file called update.jquery.bat and double click it whenever you want to update your version of jquery (or any other library). This way you can keep all your sites up to date <img src='http://dev.iamntz.com/wp-includes/images/smilies/biggrin.gif' alt=':D' class='wp-smiley' />  BE CAREFUL! Some plugins may WON&#8217;T work on newer versions of jquery! </p>
<h2>Use snippets like a smart guy!</h2>
<p>If you use <a href="http://www.e-texteditor.com/">E-texteditor</a> (and if you don&#8217;t, then YOU SHOULD!), you probably know what snippets are. But, the question is: are you using them? </p>
<p>I put some snippets all together into an archive <a href="http://iamntz.com/assets/ui.jquery.tmbundle.zip">HERE</a>. What you should do with this? Go to Start-> Run (or press WIN+R) and write this: <em>%appdata%\e\Bundles</em> then press enter. Extract the archive content right there and&#8230;. Done. </p>
<p>In each HTML document you can write <strong>ui</strong> then press tab. VOILA! A menu with jquery UI components are displayed and waiting for you to pick from there! Ofcourse, you MUST have UI files (minified) in <strong>/assets/ui</strong> folder (which must be in the root of your project folder). Again, be careful when you update UI. Even though UI 1.6 have same files as UI 1.5.2, there is (still) some issues with 1.6 (actually it&#8217;s a beta).</p>
]]></content:encoded>
			<wfw:commentRss>http://dev.iamntz.com/76/one-development-trick/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Internet Explorer List margin bug</title>
		<link>http://dev.iamntz.com/44/internet-explorer-list-margin-bug</link>
		<comments>http://dev.iamntz.com/44/internet-explorer-list-margin-bug#comments</comments>
		<pubDate>Tue, 02 Sep 2008 23:11:49 +0000</pubDate>
		<dc:creator>Staicu IonuÈ›-Bogdan</dc:creator>
				<category><![CDATA[Advices]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[CSS/XHTML]]></category>

		<guid isPermaLink="false">http://dev.iamntz.com/?p=44</guid>
		<description><![CDATA[In some (weird) cases, Internet Explorer (both 6 and 7, i didn&#8217;t use 8 yet) add an extra margin to your list elements (LI). This is very annoying and frustrating if you don&#8217;t know how to get rid of it. &#8230; <a href="http://dev.iamntz.com/44/internet-explorer-list-margin-bug">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>In some (weird) cases, Internet Explorer (both 6 and 7, i didn&#8217;t use 8 yet) add an extra margin to your list elements (<code>LI</code>). This is very annoying and frustrating if you don&#8217;t know how to get rid of it.</p>
<p>You have two solution:</p>
<p>First one, if you already coded your site and you saw the bug very lately, you can add a negative margin to list elements (either top or bottom). Every time i used this method i had no problems, so&#8230; I think it works <img src='http://dev.iamntz.com/wp-includes/images/smilies/biggrin.gif' alt=':D' class='wp-smiley' /> </p>
<p>Second one implies to use some non-semantic code. Actually&#8230; Is not always non-semantic. Sounds weird? Well&#8230; Did you ever heard of Definition Lists? <code>DL/DT/DD</code>. If yes, then start using it! IE doesn&#8217;t have any problems at all with this. If no, <a href="http://www.w3.org/TR/html401/struct/lists.html#h-10.3">read some infos</a> about this and then start using.</p>
<p>Why i tell you that is both semantic and non semantic code? For instance, on a menu, is more adequate to use <code>UL/LI</code> tags. Is a list? Ofcourse! But, you can use, as well <code>DL/DD</code> tags.</p>
<p>I know, is messy, but it works flawless <img src='http://dev.iamntz.com/wp-includes/images/smilies/biggrin.gif' alt=':D' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://dev.iamntz.com/44/internet-explorer-list-margin-bug/feed</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>jQuery AJAX trick (very useful!)</title>
		<link>http://dev.iamntz.com/34/jquery-ajax-trick-very-useful</link>
		<comments>http://dev.iamntz.com/34/jquery-ajax-trick-very-useful#comments</comments>
		<pubDate>Thu, 03 Jul 2008 00:28:22 +0000</pubDate>
		<dc:creator>Staicu IonuÈ›-Bogdan</dc:creator>
				<category><![CDATA[Advices]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[How is made?]]></category>

		<guid isPermaLink="false">http://dev.iamntz.com/?p=34</guid>
		<description><![CDATA[Did you ever ask yourself how can you display a &#8220;loading&#8221; indicator when you make ajax calls using various libraries? The simple but efficient answer is this: $(document).ready(function(){ $(' Loading... ') .ajaxStart(function() {$(this).show();}) .ajaxStop(function() {$(this).hide();}) .appendTo('body'); }); And that&#8217;s all. &#8230; <a href="http://dev.iamntz.com/34/jquery-ajax-trick-very-useful">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Did you ever ask yourself how can you display a &#8220;loading&#8221; indicator when you make ajax calls using various libraries?</p>
<p>The simple but efficient answer is this:</p>
<pre lang="javascript" line="1">
$(document).ready(function(){
$('
<div id="busy">Loading...</div>

')
        .ajaxStart(function() {$(this).show();})
        .ajaxStop(function() {$(this).hide();})
        .appendTo('body');
});
</pre>
<p>And that&#8217;s all. You need to do this only once.</p>
<p>Ofcourse, you can apply some CSS styles to #busy div, using an image generated with <a href="http://ajaxload.info/">ajaxload</a> or something similar.</p>
<p>I didn&#8217;t use any other libraries (actually i used prototype with scriptaculous sometime like AGES ago), but i think all cool libraries (like jQuery) have similar methods.</p>
<p>Another great news: with MORE than 50 fixes (but no new features tough) <a href="http://jquery.com/blog/2008/06/27/jquery-ui-151/">jQuery UI 1.5.1 is out</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://dev.iamntz.com/34/jquery-ajax-trick-very-useful/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Best way to CSS hacks</title>
		<link>http://dev.iamntz.com/14/best-css-tricks</link>
		<comments>http://dev.iamntz.com/14/best-css-tricks#comments</comments>
		<pubDate>Fri, 16 May 2008 23:21:10 +0000</pubDate>
		<dc:creator>Staicu IonuÈ›-Bogdan</dc:creator>
				<category><![CDATA[Advices]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[CSS/XHTML]]></category>

		<guid isPermaLink="false">http://dev.iamntz.com/?p=14</guid>
		<description><![CDATA[Every time you code a layout, you must dealing with inconsistencies of various browsers. Due to his lack of standard support, IE (and especially IE6) has a LOT of css hacks available &#8220;on the market&#8221;. And that because the IE &#8230; <a href="http://dev.iamntz.com/14/best-css-tricks">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Every time you code a layout, you must dealing with inconsistencies of various browsers. Due to his lack of standard support, IE (and especially IE6) has a LOT of css hacks available &#8220;on the market&#8221;. And that because the IE developer team has some kind of humor for two reason:</p>
<ol>
<li>They know that their browser suck so they put conditional comments. Is not a really hack, because you have <a href="http://msdn.microsoft.com/en-us/library/ms537512.aspx">a documentation</a>, but is the best (and also the safest) way to fix CSS bugs (or even add some extra content for certain version of IE).</li>
<li>The second reason is funny and creepy: the fresh SP3 for windows is delivered with&#8230; IE6. Yes, if you don&#8217;t have IE7 installed, you will have IE6. That sucks, isn&#8217;t it?</li>
</ol>
<p>Ok, enough with this, let&#8217;s show some real hacks, right?</p>
<h3>Internet Explorer hacks</h3>
<p>First of all: the best way is to use conditional hacks for IE. That&#8217;s because new version of other browsers can misunderstanding some hacks. As far as i know, this wasn&#8217;t happen yet, but you never know what gift we can get, right? <strong>Use hacks when you have only a couple to fixes</strong>!</p>
<p>The most used hack for IE6 is the star selector :</p>
<pre lang="css">#wrap {border:2px solid blue}
* html #wrap {border:5px solid red}</pre>
<p>For IE6, wrap container will have a 5 px border. For any other browser, you will get a 2px blue border. Is important to get IE6 hack AFTER the normal rules, otherwise you won&#8217;t get any result.</p>
<pre lang="css">html>body #wrap {background:white}
#wrap {background:red}</pre>
<p>This one is some kind of first rule, but reverted. That&#8217;s because IE6 simply don&#8217;t know how to deal with this kind of selectors (which is valid tough!). Lucky us, right?</p>
<p>Another hack is the underlined and !important. However, those hacks are NOT recommended for mass production (is ok for testing, but&#8230; that&#8217;s all):</p>
<pre lang="css">#wrap {
color:red !important;
color:blue
}</pre>
<p>and</p>
<pre lang="css">#wrap {
color:red;
_color:blue
}</pre>
<p>With both hacks you will achieve same result. But i repeat, DO NOT USE it unless you know what are doing. You will avoid a LOT of headaches <img src='http://dev.iamntz.com/wp-includes/images/smilies/wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>Until now, i talk about IE6 hacks. Here you have a IE7 hack:</p>
<pre lang="css">#header { font-size:1em }
*:first-child+html #header { font-size:2em }</pre>
<p>Like i said before, is mandatory that hack to be AFTER proper rule!</p>
<h3>IE6 min/max-width hacks</h3>
<pre lang="css">#wrap {
	width: expression(document.body.clientWidth < 742? "740px" : document.body.clientWidth > 1202? "1200px" : "auto");
	}</pre>
<p>For this one, we need to use some CSS expressions. Also, is not recommended (can affect user experience, because browser execute that expression). This hack was founded <a href="http://www.cameronmoll.com/archives/000892.html">here</a>.</p>
<h3>Image flicker problem</h3>
<p>One of the most annoying thing on IE is this: when you have a css image on a link, when you hover that link, the image is reloaded, resulting a short time flicker. Mister-pixel.com comes with a handy solution for this (that works only in IE6 SP1 or greater):</p>
<pre lang="javascript">
<script type="text/javascript" charset="utf-8">
/* <![CDATA[ */
	try {
  document.execCommand("BackgroundImageCache", false, true);
} catch(err) {}
/* ]]&gt; */
</script>
</pre>
<p>You only need to put these lines in your header (inside of conditional tags) and your problem is done.</p>
<h3>There is more?</h3>
<p>Well&#8230; I&#8217;m sure i didn&#8217;t cover all CSS hacks. However, these are some of the most important hacks, ready to use anytime you need it (and for your own good, you should bookmark this page because you will need it A LOT!). Do you know any other hacks?</p>
]]></content:encoded>
			<wfw:commentRss>http://dev.iamntz.com/14/best-css-tricks/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Best practices and advices</title>
		<link>http://dev.iamntz.com/13/best-practices-and-advices</link>
		<comments>http://dev.iamntz.com/13/best-practices-and-advices#comments</comments>
		<pubDate>Thu, 15 May 2008 19:32:57 +0000</pubDate>
		<dc:creator>Staicu IonuÈ›-Bogdan</dc:creator>
				<category><![CDATA[Advices]]></category>

		<guid isPermaLink="false">http://dev.iamntz.com/?p=13</guid>
		<description><![CDATA[As i said in previous post, i have some tips and advices for Use CSS reset This is my CSS Reset: /* resetting some default styles */ html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, &#8230; <a href="http://dev.iamntz.com/13/best-practices-and-advices">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>As i said in <a title="Best tools for development" href="stumble this pls http://dev.iamntz.com/12/best-tools-for-development">previous post</a>, i have some tips and advices for</p>
<h3>Use CSS reset</h3>
<p>This is my CSS Reset:</p>
<pre lang="css" line="1">
/* resetting some default styles */
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, font, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend{
	margin: 0;
	padding: 0;
	border: 0;
	outline: 0;
	font-size: 100%;
	vertical-align: baseline;
	background: transparent;
}
ul {list-style: none;}
body {line-height: 1;}
blockquote, q {quotes: none;}
blockquote:before, blockquote:after,
q:before, q:after {content: '';content: none;}
:focus {outline: 0;}
a:focus {outline:1px dotted #999;}
ins {text-decoration: none;}
del {text-decoration: line-through;}

table {border-collapse: collapse;border-spacing: 0;}

html { font-size:100.01%; }
body { font-size:1em; }

textarea {overflow:auto}
button {cursor:pointer}
input[type="checkbox"],
input[type="radio"],
input.radio,
input.checkbox {
	vertical-align:text-top;
}
a {text-decoration:none}
a:hover {text-decoration:underline}
/*  -----------------------------------
	a better and smarter way to clear floats
--------------------------------------*/

.clearfix:after {content:".";display:block;height:0;clear:both;visibility:hidden}
.clearfix {display:inline-block}
/* Hide from IE Mac \*/
.clearfix {display:block}
/* End hide from IE Mac */
* html .clearfix {height:1px}
/* -----------------------------------------------------------------------------------------*/
</pre>
<p>Not only i reset all styles, but i also use a smart way for clearing floats. Just add class=&#8221;clearfix&#8221; to some floatet box container and here you go. No more clear both extra tag, no more other tricks.</p>
<h3>(Don&#8217;t) Use CSS frameworks</h3>
<p>I don&#8217;t like to use code that is not mine. And CSS frameworks is this kind of code. Beside that, when you start to use a framework (no matter what framework is), you MUST learn it. Too much waste of time to learn another people code. Again, you have <a href="http://www.yaml.de/en/home.html">plenty</a> of <a href="http://code.google.com/p/blueprintcss/">CSS frameworks</a> to <a href="http://elements.projectdesigns.org/">pick and try</a>.</p>
<h3>Validate your code and search for browser bug</h3>
<p>Some times a page is not displayed well. Either you have a bug in your code or bug in your favorite browser, you need to figure in a way or other what is guilty for headaches. The best way to eliminate code bugs is to validate your code. If all lines is ok, you should <a href="http://www.positioniseverything.net/explorer.html">search</a> for <a href="http://www.positioniseverything.net/op-omnibus.html">bugs</a> in <a href="http://www.positioniseverything.net/gecko.html">browsers</a>.</p>
<h3>Comment your code</h3>
<p>You probably say: why should i bother to comment my own code? I wrote it, i will remember! Yeah, sure! Over the past years i convinced myself how much i can be WRONG! I try to read some past code (yes, written by myself) and i ask: what the heck i wanted to do here? So now i comment my code: CSS i split in blocks and on html i comment the closed div/class for big containers:</p>
<pre lang="html">
<div id="wrap">
<div class="header">
  content goes here
</div>

<!--/.header-->
</div>

<!--/wrap--></pre>
<h3>Read news, blogs and forums</h3>
<p>I have a many RSS feeds in Google Reader and half of them is about development. CSS, Javascript or only news, is all good. Of course, i don&#8217;t spend too much time reading all articles. I read only headers and if is worthing, i read it all. Is the BEST way to stay informed about web technologies.</p>
<h3>Test in many browsers</h3>
<p>Don&#8217;t matter if you made a website for yourself or for a client, because that site MUST be rendered in the same way in ALL browsers. Or at least to degrade graceful and remain usable.</p>
<h3>Use your own javascript vs. libraries</h3>
<p>Well, if you read constantly this blog, you know that i&#8217;m in love with jQuery <img src='http://dev.iamntz.com/wp-includes/images/smilies/biggrin.gif' alt=':D' class='wp-smiley' />  And for most projects i need speed in development and just to be sure i achieve same results in all browsers. I can use my own JS or i can use my own JS powered by jQuery. The second way is always preferred <img src='http://dev.iamntz.com/wp-includes/images/smilies/biggrin.gif' alt=':D' class='wp-smiley' /> </p>
<h3>More to come?</h3>
<p>Sure! If i remember any other tips, i will surely tell you! Just add this blog to your reader and stay tuned!</p>
]]></content:encoded>
			<wfw:commentRss>http://dev.iamntz.com/13/best-practices-and-advices/feed</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Best tools for development</title>
		<link>http://dev.iamntz.com/12/best-tools-for-development</link>
		<comments>http://dev.iamntz.com/12/best-tools-for-development#comments</comments>
		<pubDate>Thu, 15 May 2008 17:49:16 +0000</pubDate>
		<dc:creator>Staicu IonuÈ›-Bogdan</dc:creator>
				<category><![CDATA[Advices]]></category>

		<guid isPermaLink="false">http://dev.iamntz.com/?p=12</guid>
		<description><![CDATA[The most difficult part for a beginner developer is to find right tools for him. In fact, all developers aims straight to speed, right? For a front end developer, all basic tools you need is a text editor and many &#8230; <a href="http://dev.iamntz.com/12/best-tools-for-development">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>The most difficult part for a beginner developer is to find right tools for him. In fact, all developers aims straight to speed, right? For a front end developer, all basic tools you need is a text editor and many (as many as possible) browsers. At least in theory.</p>
<p>In real life, developer needs more than that. Here is a more than basic list with what programs i use:</p>
<ul>
<li>Adobe Photoshop. There is versions for both Mac and Win (no Linux; i will tell you later why) and it&#8217;s do his job very well. If is too big for what you need (and almost every time is too big), you can try his little brother Fireworks. You need only a soft for making slice and play with layers, so if you can find another software for doing this, let me know.</li>
<li>Text editor. There is a PLENTY of editors, one better than other and you only need to pick one. Ofcourse, you don&#8217;t have to be stuck with that editor because anytime you can find a better one. I used <a href="http://www.adobe.com/products/dreamweaver/">Dreamweaver</a> for about one year (or even more). I found <a href="http://www.ultraedit.com/products/uestudio.html">UEstudio</a> and i used for another year or so and last year i found a great <a href="http://macromates.com/">TextMate</a> port for Windows: <a href="http://www.e-texteditor.com">e-Texteditor</a>. And for now i think is the best (still having bad parts, but if i put side by side all editors, e is the ONE) and for now i don&#8217;t think to change it. The best thing is if you use e for a while and you want to switch on Mac with all your e custom bundles and themes, just DO IT! Working like a charm. Ofcourse, you can find a HUGE number of editors: Aptana, Zend (yes, some guys are using this not only for PHP), Eclipse, Intype (is some kind of e or textmate), Komodo, Maguma, GoLive!, <a href="http://notepad-plus.sourceforge.net/">Notepad++</a> and so on.</li>
<li>VMWare, Parallels, VirtualPC or any other software that will allow you to run another OS in your current OS. Again, there is versions for both Mac and PC. This is to be sure that your site will be displayed like you want in ALL browser (or as many as possible). I&#8217;m sure you don&#8217;t want a site that is looking good on IE7 and is screwed up in IE6, right? I use Vista as main OS, OsX as secondary OS (yes, Hackintosh) and Windows XP with IE6 and Ubuntu 8.08 on my virtual machine.</li>
<li>Apache, php and mysql. Either you installing this manually or install a all-in-one package (<a href="http://www.apachefriends.org/en/xampp.html">Xammp</a>, <a href="http://www.easyphp.org/">EasyPHP</a>), you probably need a server like that if you plan to develop themes for CMS/Forums or Blogs. For Movable type, for example, you also need too install Perl.</li>
<li>If you are working on big projects with many developers, you should consider to use SVN and a <a href="http://tortoisesvn.net/">SVN client</a>.</li>
<li>Patience. A HUGE dose of patience, because will be a LOT of stuff that will simply won&#8217;t work on some browser (usually IE6) and if you don&#8217;t know what to do, you will get some white hair before the time <img src='http://dev.iamntz.com/wp-includes/images/smilies/biggrin.gif' alt=':D' class='wp-smiley' /> </li>
<li><a href="http://www.foobar2000.org/">A music player</a> <img src='http://dev.iamntz.com/wp-includes/images/smilies/biggrin.gif' alt=':D' class='wp-smiley' />  I don&#8217;t know how do you code, but i can&#8217;t code in absolutely silence. I search for a radio station and just play at a low volume.</li>
</ul>
<p>As i said before, i will tell you why you don&#8217;t have some of these tools on you Linux box (but maybe you have many other great tools): there is a tremendous number of Linux distribution with a huge number of configuration and Adobe (and many other companies) don&#8217;t want to spend time with technical support (just imagine a call center operator who MUST resolve problems of 20 distro/day!). For front end development i personally think is a MUST to have Windows or Osx (or even both).</p>
<p>Soon i will post a guide with best practices and some advices for front end developers.</p>
]]></content:encoded>
			<wfw:commentRss>http://dev.iamntz.com/12/best-tools-for-development/feed</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
	</channel>
</rss>

