Monthly Archives: September 2009

Readtwit – Publish twitter links to RSS feeds

Readtwit

If you’ve ever found yourself having trouble keeping track of links posted by your Twitter friends, then there’s a new Twitter app that should be right up your alley.

The app? Readtwit.

It’s mission? Convert links posted by your Twitter friends into RSS feeds.

The setup

I just setup Readtwit about an hour ago and I’m already digging the ability to link it with my other RSS feeds in Google Reader. Now I can check out tweeted links on my own time. Best yet it’s free and the setup is super easy (it only takes like 3 steps).

Previously I had been keeping track of links that looked interesting by marking them as a favorite for later digesting. The problem with that approach: I always forgot to check out my favorites. With Readtwit I am hopeful that Twitter favorites become a thing of the past (at least one step closer).

Best yet, I can avoid missing links that are important to me, even when I take a Twitter holiday.

Blacklisting features

The first blacklisting feature lets you blacklist certain friends. I have already made use of this feature by blocking links that I know are time sensitive. For example I follow @amazondeals to get notification of Amazon’s lightning deals ( each deal expires in just hours).

The second blacklisting feature is to blacklist certain tags. Currently I don’t have a reason to use this feature, but I can see some uses for it.

Other features

While I haven’t had time to test this feature (it happens automatically), Readtwit has the ability remove duplicate links. I am curious how much time must pass before a link is no longer considered a duplicate.

Another feature to reverse shortened URLs. As you can imagine, tinyurl.com followed by a bunch of jibberish doesn’t help me much in determining what items in my RSS feed is worth reading and what is rubbish.

My wishlist

I think it would be useful to continue with the blacklisting theme and blacklist anything from specific URLs, tweets with certain words (most people don’t use hashtags religiously or at all), and blacklist URLs with specific words in the linked article.

Readtwit does not have any features for whitelisting. That’s unfortunate. If I only wanted a small subset of my friends tweeted links, I would have to blacklist 70+ people. That’s far too tedious.

Bottom line

Overall Readtwit looks very promising. I really like the concept and hopefully I can get some good use out of it. Existing blacklisting features are already helpful, but I’d like to see more blacklisting abilities. I’d also like to see whitelisting features. One thing is certain, Readtwit is worth it’s price and worth a try.

Handling empty options with Ext JS combo box

Ext JS works great at easily transform plain vanilla combo boxes into powerful auto-complete combo boxes. I ran into an issue with an empty combo box option (that is <option/>).

Bad height for empty option

Bad height for empty option

Out of the box Ext JS handles <option/> by giving it a height of just a few pixels. Since there is no display value specified, all that we’re left with is the padding of the Ext JS rendered option. This isn’t desirable because it is not easy to select and it is counter to how <option/> is rendered in browsers.

Inadequate solutions

A variety of solutions I was able to Google suggested to use <option>&nbsp;</option> instead of <option/>. When the user starts typing, a nearly invisible space appears before the text and auto-complete brings back nothing. So unfortunately this breaks the user experience if this is the option currently selected. It also breaks the emptyText property in Ext JS.

Template solution

We can work around this by introducing a template:

[javascript]
new Ext.form.ComboBox({
typeAhead: true,
triggerAction: ‘all’,
transform:’number’,
width:135,
forceSelection:true,
emptyText:’Select a number…’,
allowBlank:true,
tpl:'<tpl for=".">’ +
‘<div class="x-combo-list-item">’ +
‘{text}&nbsp;’ +
‘</div></tpl>’
});
[/javascript]

This template will create an Ext JS combo box that is very similar to a plain combo box:

Correct height for an empty option

Correct height for an empty option

This solution works by adding a space (&nbsp;) of the text Ext JS displays. Because only Ext JS’s rendering of a combo box is changed, the actual combo box display value and value do not change.

This isn’t a horrible solution, but it would be nice if Ext JS handled this sort of thing out of the box.

Easily convert existing combobox to autocomplete with Ext JS

I’m impressed with at least one feature of Ext JS. If you want to convert an already existing select to an autocomplete-enabled combobox/textbox, it’s ridiculously easy.

Given this combobox:

[html]
<select id="number" name="number">
<option/>
<option value="1">ONE</option>
<option value="2">TWO</option>
<option value="3">THREE</option>
<option value="4">FOUR</option>
<option value="5">FIVE</option>
<option value="6">SIX</option>
</select>
[/html]

To convert this select box into an autocomplete combobox/textbox with Ext JS takes just a tiny bit of JavaScript:

[javascript]
Ext.onReady(function()
{
new Ext.form.ComboBox({
typeAhead: true,
triggerAction: ‘all’,
transform:’number’,
width:135,
forceSelection:true,
emptyText:’Select a number…’
});
});
[/javascript]

Such a simple way to turn a typical dropdown into an autocomplete combo box.

Picture gallery

Original dropdown

Original dropdown

Autocomplete dropdown, nothing selected title=

Autocomplete dropdown with no selections (using Ext JS)

Autocomplete in action

Autocomplete in action