Sunday, September 28, 2008

Pageant Sash and Tina Fey Glasses

I'm not a big SNL fan probably because I don't have a lot of time to wacth it but I have to give it to them. I almost had an asthma attack watching this one. My favorite part, where I literally fell to the ground laughing with tears in my eyes ...

FEY AS PALIN: "What an amazing time we live in. To think that just two years ago, I was a small town mayor of Alaska's crystal meth capitol. And now I am just one heartbeat away from being President of the United States. It just goes to show that anyone can be President."

POEHLER AS CLINTON: "Anyone."

FEY AS PALIN: "All you have to do is want it."

POEHLER AS CLINTON: (LAUGHS) "Yeah, you know, Sarah, looking back, if I could change one thing, I should have wanted it more." (RIPS OFF PIECE OF PODIUM)

Excerpt is from About.com. Check out About.com's political humor section by clicking the title above for the complete transcript of the skit.

Have a look and a laugh or worse an asthma attack from the entire SNL intro skit from NBC.com below.



Update : I just found out that Tina Fey reprised her role as Sarah Palin in another intro skit just last night. I don't think it was as funny as the first one but judge for yourselves, here's the video from NBC.com.

Monday, September 22, 2008

Use javascript to prevent firefox from loading stuff into your page

So say you have a cool Photo web application. It's so cool that people think that they can just drag photos from their desktop to anywhere on the page and it'll get uploaded, NOT.

Well at least not yet.

What happens is that firefox loads up the image totally replacing your page. To avoid that, add this line of code at the head of your html page and you should be all set.

window.addEventListener('dragdrop', function(event) { event.stopPropagation() }, false)

Changing HTML tag attributes with Javascript

Just in case I forget all about this and I'm sure someone may find it useful.

It's probably commonplace to access certain attributes like style and class but what if you want to set your own attributes on an html tag.

On ExtJS, you can add a quicktip to any html element by simpley adding "ext:qtip" attribute like so.

<div id='mydiv' ext:qtip='Empty div'>

Now what if you want to add or dynamically change the qtip on that element. Here's how I did it.

var newtip = document.createAttribute('ext:qtip');
newtip.value = "It's not empty anymore";
document.getElementById('mydifv).attributes.setNamedItem(newtip);

Sunday, September 07, 2008

Thoughts about YNG (YUI the Next Generation)

Yes, I'm a trekkie :-) So follow the link (click the title) already and find out what I think of YUI 3.0 over at the Solutiongrove Blog.

Wednesday, September 03, 2008

Google Chrome : First Impressions

Google Chrome Beta went live a few hours ago and I just couldn't resist installing it and giving it a spin.

I'm a bit disappointed that I had to boot up a virtual machine with windows to try it out as a Linux version of the browser isn't available yet but overall my experience with it has been positive so far.

It does somewhat remind me of Opera for some strange reason.

If this is the first time you've heard about Chrome, Google made available a nice online comic book explaining in layman's terms why they decided to create their own browser.

Download and Install

Download and install was easy. After clicking Download Google Chrome I was redirected to accept their terms of service. After that an application popup with a progress bar appears and shows me the download status. I appreaciate how I didn't have to download an installer and double click it afterwards. Google downloaded Chrome and started the install for me. How nice is that.

Once installation completes Chrome will import bookmarks and other resources from Firefox. There doesn't seem to be a way to opt out of that. It so happens that my Firefox browser was running and it warned me that it couldn't import stuff from a running browser. There was a button to Skip Import so I clicked that instead of turning off Firefox and letting it do the import.

Taking it for a Spin

Excited to see how this new browser does Ajax and DHTML,

I loaded up the Solutiongrove.com portal page ...

chrome-sgcom

... and our Friend Webs facebook app

chrome-fw

Not bad !

Flash, SVG, Ajax and Javascript all work nicely and quite fast too. Java it seems though isn't supported yet.


chrome-javaplugin

Developer Tools

The saddest part about this is that I may one day (if it manages to steal enough market share from IE and Firefox) need to include this browser in our QA process. However, Google hasn't forgotten us web developers when they released chrome. They included some developer tools (see screenshots below) which you can access by clicking the "control the current page icon".

chrome-icon

It's hard to say whether these tools will be as good as Firebug on Firefox but at least they're there.

chrome-jsconsole-res


chrome-jsconsole-el

Final Words

Download and install is streamlined and easy especially for novices.

Browsing is fast and the software feels stable.

Google hasn't forgotten web developers with this browser thanks to the inclusion of developer tools.

Tuesday, September 02, 2008

Google Chrome

2 years ago I mentioned in a blog post how the browser will play pivotal role in implementing COMET.

Today Google is stepping up with their own web browser. It's too early to say whether this new browser will herald the coming of faster, more powerful web apps, however, if the comic is any indication, Google is giving Mozilla and Microsoft a serious run for their money.