<?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>DECAF° blog für digitale kommunikation &#187; jQuery</title>
	<atom:link href="http://blog.decaf.de/schlagwort/jquery/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.decaf.de</link>
	<description></description>
	<lastBuildDate>Fri, 27 Aug 2010 08:05:05 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Mark external links and open in new window/tab (jQuery)</title>
		<link>http://blog.decaf.de/2010/01/mark-external-links-and-open-in-new-windowtab-jquery/</link>
		<comments>http://blog.decaf.de/2010/01/mark-external-links-and-open-in-new-windowtab-jquery/#comments</comments>
		<pubDate>Mon, 04 Jan 2010 11:50:23 +0000</pubDate>
		<dc:creator>Dirk Schürjohann</dc:creator>
				<category><![CDATA[#]]></category>
		<category><![CDATA[jQuery]]></category>

		<guid isPermaLink="false">http://blog.decaf.de/?p=979</guid>
		<description><![CDATA[Specs: filter external links (check the hostname) filter links marked as rel="external" filter links in image maps (area) as well text links only (do not contain img, div or mailto): add CSS class .external providing an additional icon open external links in new window/tab The code (jQuery): $(document).ready(function(){ $('a, area').filter(function() { return this.hostname &#038;&#038; (this.hostname).split(":")[0] ]]></description>
			<content:encoded><![CDATA[<p><strong>Specs:</strong></p>
<ol>
<li>filter external links (check the hostname)</li>
<li>filter links marked as <code>rel="external"</code></li>
<li>filter links in image maps (<code>area</code>) as well</li>
<li>text links only (do not contain <code>img</code>, <code>div</code> or <code>mailto</code>): add CSS class <code>.external</code> providing an additional icon</li>
<li>open external links in new window/tab</li>
</ol>
<p><strong>The code (jQuery):</strong></p>
<pre><code allow="none">
$(document).ready(function(){
  $('a, area').filter(function() {
    return this.hostname &#038;&#038; (this.hostname).split(":")[0]
      !== (location.hostname).split(":")[0]
    || $(this).attr('rel') == 'external';
  })
  .not(':has(img, div, mailto)')
  .addClass('external')
  .end()
  .click(function(e) {
    open(this.href);
    e.preventDefault();
  });
});
</code></pre>
<p><span id="more-979"></span><strong>Notes:</strong></p>
<ul>
<li>Why not mark external links containing <code>images</code>, <code>div</code> or <code>mailto</code> with CSS class <code>.external</code>? This is because we want to add the icon to pure text links only. Links containing images or whatever kind of block elements may disturb the site layout if an additional icon would be added.</li>
<li>Use <code>rel="external"</code> to force opening a link in a new window/tab.</li>
</ul>
<p><strong>CSS providing an icon <img class="inline" src="http://blog.decaf.de/wp-content/themes/decaf_2/static/images/icon_external.png" alt="" /> for external links marked with class .external:</strong></p>
<pre><code allow="none">
a.external {
  background-image: url(icon_external.png);
  background-position: right top;
  background-repeat: no-repeat;
  padding-right: 11px;
  zoom: 1; /* IE */
}
</code></pre>
<p>(Inspired by <a href="http://www.learningjquery.com/2008/08/quick-tip-dynamically-add-an-icon-for-external-links">Karl Swedberg at learningjquery.com</a>.)</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.decaf.de/2010/01/mark-external-links-and-open-in-new-windowtab-jquery/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>iPhone-like password fields using jQuery</title>
		<link>http://blog.decaf.de/2009/07/iphone-like-password-fields-using-jquery/</link>
		<comments>http://blog.decaf.de/2009/07/iphone-like-password-fields-using-jquery/#comments</comments>
		<pubDate>Tue, 07 Jul 2009 14:03:14 +0000</pubDate>
		<dc:creator>Stefan Ullrich</dc:creator>
				<category><![CDATA[#]]></category>
		<category><![CDATA[Wichtige Artikel]]></category>
		<category><![CDATA[Formulare]]></category>
		<category><![CDATA[iPhone]]></category>
		<category><![CDATA[jQuery]]></category>

		<guid isPermaLink="false">http://blog.decaf.de/?p=938</guid>
		<description><![CDATA[or: Delayed password masking with JavaScript. 8/19/09 FYI: Upcoming version of the plugin will be released in a few days. It’s gonna fix the current issues very well. Jakob Nielsen recently asked us to Stop Password Masking: Usability suffers when users type in passwords and the only feedback they get is a row of bullets. ]]></description>
			<content:encoded><![CDATA[<p><strong>or: Delayed password masking with JavaScript.</strong></p>
<div style="background: #FFFBDD; padding: 5px; margin-bottom: 20px;">
<p style="margin: 0">8/19/09 FYI: Upcoming version of the plugin will be released in a few days. It’s gonna fix the current issues very well.</p>
</div>
<p>Jakob Nielsen recently asked us to <a href="http://www.useit.com/alertbox/passwords.html">Stop Password Masking</a>:</p>
<blockquote><p>Usability suffers when users type in passwords and the only feedback they get is a row of bullets. Typically, masking passwords doesn&#8217;t even increase security, but it does cost you business due to login failures.</p>
<p><cite>- <a href="http://www.useit.com/alertbox/passwords.html">useit.com/alertbox/passwords.html</a></cite></p></blockquote>
<p>He suggests using <strong>plain text input fields by default</strong> and offering a <strong>checkbox</strong> to have the passwords masked.</p>
<p>We do not completely go for the idea of typing passwords in plain text by default as there <em>will</em> be a loss of security! Not a technical one, but a user-driven one.</p>
<div class="clear mb1"></div>
<h3>Password fields on iPhone/iPod touch</h3>
<p><img src="http://blog.decaf.de/wp-content/uploads/iphone-password.jpg" alt="iphone-password" title="iphone-password" width="262" height="362" style="float: right; margin: 0 0 5px 10px;" />Of course Nielsen is right when he talks about users making more errors and feeling less confident when they can&#8217;t see what they&#8217;re typing while filling in forms. That may have been the reason why Apple <del>developed</del> implemented an alternative method on <strong>iPhone/iPod Touch</strong>: passwords get masked while typing but the last character in row is shown in plain text. Compared to common password fields on the web this method improves usability, not only on mobile devices. And concerning security risks you&#8217;ll probably need James Bond behind your back looking over your shoulders in order to let your password be captured.</p>
<p>So, this method looks to be a pretty good way of typing in passwords, and that is why tried to use it on web forms. It comes as a <strong>jQuery plugin</strong> which works unobtrusive. Non-JS users get the common masked password fields.</p>
<p>Copy &#038; paste will work as usual. The only thing that will not work is: deleting/inserting single or multiple characters from the beginning/middle of the masked password string.<br />
But, let&#8217;s face it, who will do that?</p>
<div class="clear mb1"></div>
<h2 class="mb1">Live demo</h2>
<div style="background: #E6EDF0; padding: 10px;"><label for="test">Type in a random password:</label><br />
<input id="test" type="password" style="width: 450px; font-size: 20px; margin-right: 10px;" /><a href="#" id="show_password">show password</a></div>
<p><script type="text/javascript" src="http://blog.decaf.de/wp-content/uploads/jQuery.dPassword.js"></script><script type="text/javascript">
$(document).ready( function() {
	$('input:password').dPassword();
	$('#show_password').click( function() {
		alert('The password you entered is: '+$('#test').val());
		return false;
	});
});
</script></p>
<p><span id="more-938"></span>
<div class="clear mb1"></div>
<h3>Features</h3>
<ol>
<li>Doesn&#8217;t need any HTML modification as it finds password fields by type.</li>
<li>Unobtrusive: Non-JS users get the common masked password fields.</li>
<li>Supports copy &#038; paste.</li>
<li>Options: Interval, delay, replacement character, prefix, debug mode.</li>
</ol>
<div class="clear mb1"></div>
<h3>Instructions</h3>
<p>It&#8217;s very simple. </p>
<ol>
<li>Just load jQuery, of course ;-).</li>
<li>Load the Plugin</li>
<li>and then initialize dPassword.</li>
</ol>
<p>You are done!</p>
<pre><code allow="none">
<script type="text/javascript" src="/js/jquery.js"></script>
<script type="text/javascript" src="/js/jQuery.dPassword.js"></script>
<script type="text/javascript">
	$(document).ready( function() {
		$('input:password').dPassword();
	});
</script>
</code></pre>
<p>There are some options you might want to configure:</p>
<ul>
<li><strong>interval</strong><br />Time in msec the scripts checks for newly entered characters.</li>
<li><strong>duration</strong><br />Delay in msec of converting the last entered character.</li>
<li><strong>replacement</strong><br />The character to be replaced, for unicode characters use the following format: <code>%u25CF</code><br />You may check these ressources: <a href="http://www.utf8-chartable.de" rel="external">Overview of unicode characters</a> or a more comprehensive <a href="http://www.fileformat.info/format/w3c/entitytest.htm?sort=Unicode+Character" rel="external">overview</a>.</li>
<li><strong>prefix</strong><br />This is the prefix of the newsly generated elements. Default is <code>password_</code>.</li>
<li><strong>debug</strong><br />For debugging issues. You need FireBug enabled!</li>
</ul>
<p>Example:</p>
<pre><code allow="none">
<script type="text/javascript" src="/js/jquery.js"></script>
<script type="text/javascript" src="/js/jQuery.dPassword.js"></script>
<script type="text/javascript">
	$(document).ready( function() {
		$('input:password').dPassword({
			duration: 2000,
			prefix: 'my_'
		});
	});
</script>
</code></pre>
<div class="clear mb1"></div>
<h3>Known Issues</h3>
<ol>
<li>Adding/deleting chars from the middle doesn&#8217;t work. Works at the end of the password only.</li>
<li>View will not follow cursor if input field is too small.</li>
<li>If #id based CSS styles are assigned, these styles will not be taken over.</li>
</ol>
<div class="clear mb1"></div>
<h3>Download</h3>
<div style="background: #E6EDF0; padding: 10px 10px 0 10px;">
<img style="float: left; margin-right: 20px;" src="http://blog.decaf.de/wp-content/uploads/defaultlogo.png" alt="defaultlogo" title="defaultlogo" width="48" height="48" />
<div style="overflow: hidden;">
<p>
<strong>Project page with SVN repository: <a href="http://code.google.com/p/dpassword/">http://code.google.com/p/dpassword/</a></strong><br />
JS download: <a href="http://dpassword.googlecode.com/svn/trunk/lib/jQuery.dPassword.js">jQuery.dPassword.js</a><br />
Complete ZIP download: <a href="http://dpassword.googlecode.com/files/dpassword.zip">dpassword.zip</a>
</p>
</div>
<div class="clear"></div>
</div>
]]></content:encoded>
			<wfw:commentRss>http://blog.decaf.de/2009/07/iphone-like-password-fields-using-jquery/feed/</wfw:commentRss>
		<slash:comments>64</slash:comments>
		</item>
	</channel>
</rss>
