JavaScript, webdev

25 Good (to Great) jQuery plugin to keep in mind

Here are few good (and some great) jQuery plug-ins that can boost your next proejct.

Cookie

Source:  http://plugins.jquery.com/project/cookie

Set and get cookies with jQuery.

Slideshows

There are lots of them, but this one is good in terms of the set of features.

http://jquery.malsup.com/cycle/ Slideshow plugin that supports many different types of transition effects.

Another option (simpler) is jCarousel:

http://sorgalla.com/jcarousel/ Control a list of items in horizontal or vertical order.

Date Range Picker

http://www.filamentgroup.com/lab/date_range_picker_using_jquery_ui_16_and_jquery_ui_css_framework/

Built on jQuery UI. You might want to use it only if the ‘default’ jQuery UI widget is not enough for you.

Flip

Simple & cool animation: http://lab.smashup.it/flip/

Flip your elements in four directions.

Flot: Charting

Source: http://code.google.com/p/flot/

A pure Javascript plotting library for jQuery. It produces graphical plots of arbitrary datasets on-the-fly client-side.

Form

Source: http://jquery.malsup.com/form/

Allows you to easily and unobtrusively upgrade HTML forms to use AJAX.

Hotkeys: Keyboard Bindings

http://code.google.com/p/js-hotkeys/ if you want your web app to be ‘reachable’ using keyboard – this is your plugin: Add and remove handlers for keyboard events anywhere in your code supporting almost any key combination.

Masked Input

Selection: http://digitalbush.com/projects/masked-input-plugin/

Allows a user to more easily enter fixed width input where you would like them to enter the data in a certain format (dates,phone numbers, etc).

Jcrop

Source: http://deepliquid.com/content/Jcrop.html

A quick and easy way to add image cropping functionality to your web application

jGrowl: Messaging System

Source: http://stanlemon.net/projects/jgrowl.html

Unobtrusive messages within the browser, similar to the way that OS X’s Growl Framework works

jqGrid

Source: http://www.trirand.com/jqgridwiki/doku.php

Represent and manipulate tabular data on the web.

JSON: Utility

Source: http://code.google.com/p/jquery-json/

Serializes a javascript object, number, string, or array into JSON (and a few other utilities).

JS Tree

Source: http://www.jstree.com/

jsTree is a javascript based, cross browser tree component.

UI Layout

Source: http://layout.jquery-dev.net/

Create any UI look you want – from simple headers or sidebars, to a complex application with toolbars, menus, help-panels, status bars, sub-forms, etc.

MarkItUp

Source: http://markitup.jaysalvat.com/home/

Allows you to turn any textarea into a markup editor.

Meta Data

Source: http://plugins.jquery.com/project/metadata

Extract metadata from classes, random attributes, child elements and HTML5 data-* attributes.

Popeye: Inline Gallery

Source: http://dev.herr-schuessler.de/jquery/popeye/

An advanced image gallery used to save space when displaying a collection of images and offer your users a nice and elegant way to show a big version of your images without leaving the page flow.

Quicksand: Animated Filtering

Source: http://razorjack.net/quicksand/

Reorder and filter items with a nice shuffling animation.

scrollTo

Source: http://flesler.blogspot.com/2007/10/jqueryscrollto.html

A small, customizable plugin for scrolling elements, or the window itself.

Spell Check

Source: http://github.com/brandonaaron/jquery-spellcheck

Adds spellcheck support to inputs. It uses Google’s spell checking API and requires a server to handle the communication with the API. An example php implementation is provided.

Star Rating

Source: http://www.fyneworks.com/jquery/star-rating/

Creates a non-obstrusive star rating control based on a set of radio input boxes.

Table Sorter

Source: http://tablesorter.com/docs/

Turn standard HTML table with THEAD and TBODY tags into a sortable table without page refreshes.

Uniform

Source: http://pixelmatrixdesign.com/uniform/

Uniform masks your standard form controls with custom themed controls.

Validate

Source: http://bassistance.de/jquery-plugins/jquery-plugin-validation/

Add client-side validation to your forms.

Standard
Business, life

What Are The Top 10 Interview Questions You Would Ask?

Question in the sky

I’ve thought about some ideas on how we can learn quickly who is sitting in front of us. Yes, I’ve being doing lots of interviews to candidates and it seems to me that the normal technical questions tell nothing. I’m more and more interesting in a try to understand the person and see if there is a real win-win situation.

Over the years, I’ve learn that these 4 questions will give you a good idea about the developer/product manager/designer you wish to hire:

1. What are you excel at?
A nice way to touch on the strengths. What you references will tell me about you?
Btw, ask for a few references and call them. You will be surprise how much you can learn from them.

2. What is your one weakness you wish to improve?
Well – everyone got something that they can improve. It’s interesting to hear the ‘music’ of the answer and less the content. If they say something positive in a custom of negative (e.g. “I’m stubborn and won’t let a problem break me”), you know you have a problem.

3. Where do you wish to see yourself in the next job?
This will help you understand what they wish to do later in life. I used to ask this question with a time aspect (e.g. in 3-4 years) but it’s better to keep it with out time limit as no one knows how long they will move on.

4. What is the one thing that you know to be true that many others think to be false?
I ‘borrowed’ this one. It’s really good.

As for more general questions that I find useful to ‘tell’ you more about the person:

  • What book is your favorite one?
  • What activity you like most?
  • Name you best: movie, song, band, vacation place.

Last but not least, there is the famous list of Bernard Pivot. It’s great not only on celebrities but on your friend at parties as well, specially, if they had few drinks before. Drinks are useful to help them drop the masks.

1. What is your favorite word?
2. What is your least favorite word?
3. What turns you on?
4. What turns you off?
5. What sound or noise do you love?
6. What sound or noise do you hate?
7. What is your favorite curse word?
8. What profession other than your own would you like to attempt?
9. What profession would you not like to do?
10. If Heaven exists, what would you like to hear God say when you arrive at the Pearly Gates?

Standard
Business, webdev

Mobile Is (going to be) The Biggest Platform

What can we learn from the creators of Angry Birds? Rovio (the company that created this game) reports an average of 65 million minutes of game-play per day.

It’s hard to believe. Few good points to take out form this 5min video:

  • Simplicity win (again). Easy to jump in and hard to jump out.
  • Keep thinking on users (retention). Offer, free upgrades and keep your users happy.
  • Build for all the platforms: iPhone, Andriod, WebOS etc’.
Standard
life, travel

Telluride, Colorado – It’s Winter Time

Snow Time in the mountains.
It’s all about being deep in nature and having a blast. When I’ll retire, this is where I’m going to spend my winters.

The White Power

The White Power

Standard
Business, life

Changing Education – From The Best Sir Ken Robinson

From his first talk (that I’ve watched) at TED, it was clear he is one of the great thinkers today that devote his mind to education and how we could/should fix it.

This video is another profe to his deep and strong ideas, plus you can enjoy the animation on the way.

 

Standard
Sport

What A (Redbull) Rider

This Red bull Rider is out of this world – don’t take my word, watch it:

The new riding clip from Danny MacAskill.

It follows him on a journey from Edinburgh back to his hometown Dunvegan, in the Isle of Skye.

Here it is in our world:Dunvegan, in the Isle of Skye

Standard
Business

Never feel sorry for yourself

Here are few notes I’ve wrote down after I saw this powerful talk of Charlie Munger.

  • Never feel sorry for yourself
  • Never feel envy.
  • Good waves and Bad waves – so what?

If you don’t know who is Charlie Munger – well, he is the CEO of Berkshire Hathaway AND the one person that Buffett suggest you save if both of them are on a sinking ship!

BTW, his full talk, is very interesting but I took one thing that was above the ‘ordinary’ – “…On philanthropy: Generally speaking, I believe Costco (Nasdaq: COST) does more for civilization than the Rockefeller Foundation. I think it’s a better place. You get a bunch of very intelligent people sitting around trying to do good, and I immediately get kind of suspicious and squirm in my seat. That may be a prejudice of mine which isn’t quite fair. But I’ve seen so much good in the world by people who really created better systems, and I’ve seen so much folly and stupidity on the part of our major philanthropic groups, including the World Bank, that I really have more confidence in building up the more capitalistic ventures like Costco.”

Standard
life

How To Harness The Good Bugs To Fight For You

I wish I saw part of this TEDx which took place last April in Tel Aviv. Shimon Steinberg looks at the difference between pests and bugs and makes the case for using good bugs to fight bad bugs, avoiding chemicals in our quest for perfect produce. It’s very cool, greener, organic way to approach our battles in the fields.


TEDxTelAviv – may be next year.

Standard
php, webdev

ZendCon 2010 – Caching on the Edge

PHP Caching on the Edge

The goal is to never generate the same response twice.
This is another ‘notes post’ – nothing too organize here (for now).

Changing the HTTP headers with php:
header(‘Content-Type: text/plain’);

Caching  spec – read it on the night you feel like you can’t sleep.

1. HTTP expiration

Is the data fresh? only when the version is stale we will go to the server to get a new data.
HTTP Headers for Expiration

2. HTTP validation

Last-Modified / If-Modified-Since
ETag / If-None-Match

(!) Http cache headers only work with ‘safe’ HTTP methods (GET/HEAD) – meaning, these method won’t change the application state.

Expires – give the date/time after which the response is considered stale.
$expires – gmdate(‘D, j M Y H:i:s T’, time()+5); // expire in 5sec
header(‘Expires: ‘ . $expires);

* With expiration of less then few days you might hit problems because the clock in the web server and the clock in the client is not showing the same time.
* HTTP/1.1 spec says that you are not allowed to send expire for more then 1 year in the future. WHY?

A better way:
* Use cache-control
header (‘Cache-Control: max-age=5’);

(!) So use expire only for things you want to cache for very long time (more then 48h).
On other cases, use cache-control.

Usage of ETag

You can compute the etag on your own or use a tool that do the work for you (some good framework).
ex: http://http.trainings.sensiolabs.com/etag.php

* Expiration wins over Validation – first we checking the expiration.
* Expiration allows you to scale as less requests hit your server.
Validation saves bandwidth.

PHP and cache

http://http.trainings.sensiolabs.com/cookie.php

session_start();
$_SESSION['foo'] = 'bla';

(!) By default – when you set a cookie… php set for YOU no-cache/no-store/must-revalidate
Because if you have a cookie, you don’t want to cache the page.
It’s more a ‘safe’ default. So no one else could take this information from you.

header(‘Cache-Control: private/public, max-age=5’);
private – will prevent any proxy from cache this page.

Types of Caches

1. Browser cache – for example it’s good for images.

2. Proxy cache – inside a company/organization. It still on the ‘client side’ and it will mask all the clients that site behind it.
We can find it in big companies and lots of ISPs. It’s public.

3. Gateway cache (=reverse proxy or Http Accelerator or Surrogate Cache) – This is just like a proxy BUT it is on the server side.
Shared cache on the server side. Make your site more scalable, reliable and improve performance.

Gateway cache

In practice, most caches avoid anything with: cache-control, cookie, www-authenticate, post/Put, 302/307 status codes.
Cache-Control in php save us with a safe default of ‘private’.

A gateway cache won’t cache anything ‘private’ or carrying a cookie – so how can we use Google Analytic and still have cache?
use varnish… or any other proxy that remove+add the cookies before the request hit the server.

In cases where you want your code to run with reverse proxy like Akamai/varnish (esi tag is supported) you should use:

Surrogate-Capability: abc=”Surrogate/1.0 ESI/1.0″
Surrogate-Control: content =”ESI/1.0″ <– this will let the reverse proxy to parse the tags.

(!) You need to set these features in Varnish (they are not there by default).

Symfony2 – got a reverse proxy that is written in PHP. You might want to use it if you can’t afford to use varnish (it’s free – but let say your hosting company won’t install it)

In the end of the day, you want to hit the application as less as possible.
You can do it with HTTP headers and ESI.

Last but not least, please remember that, the one who picks his targets carefully, acts quietly, and achieves his objectives — he wins wars.

Standard