Archive for February, 2008

jQuery tablesorter plugin – a friend in need…

Working on Client side using javascript has lot of advantages and one of them I came across today..! In our flagship CRM we have quite complicated and drill-down reports and in one of such report I wanted to give sorting.

It was not possible to use database (mySQL) sorting as it was not just one query and it was a calculated based on so many things. Next option was to play with resultant recordset in script language - PHP, although I am very good at playing with arrays I didn't wanted to do so in it this time. I had seen many of jQuery examples previously and since few months I was heavily developing in jQuery so I though of doing it on client end using some javascript code. Which I though must be readily available by some great contributor over the Internet.

I did my search with "table sort jquery" and what I found was a great jQuery plugin with a great power which will let me do all my sorting on Client Side. I was not going to give pagination on that so server side trip was not required at all.

tablesorter is a great jQuery plugin and I applicate all efforts from Christian Bach to make this plugin what it is, and tablesorter is now in mature stage by his efforts. When I am writing it is in it's 2.0.1 version.

I agree that such plugins are available by contributors of other javascript frameworks like Prototype, mootools...etc. But what jQuery has done is really great. Plugin development is really easy and fun with jQuery, and it's beauty, chain ability and ease will drive us crazy to get anything we want.......!

So if you are already using jQuery for your application just use tablesorter when you need it and it won't let you down. Using it is really a fun and as easy as ("#myTable").tablesorter() and you are done. It will auto-detect most of the data-type on it's own and you can checkout from it's demos that it really does. It will just take plain html table and we just need to leave everything else on this beautiful plugin to worry about.

Here is the powerful feature list:

  • Multi-column sorting
  • Parsers for sorting text, URIs, integers, currency, floats, IP addresses, dates (ISO, long and short formats), time. Add your own easily
  • Support for ROWSPAN and COLSPAN on TH elements
  • Support secondary "hidden" sorting (e.g., maintain alphabetical sort when sorting on other criteria)
  • Extensibility via widget system
  • Small code size (7,4kb packed)


Real simplicity of plugin is that I don't need to change much to use it. I can output plain html as I was doing before, just attach id=<table-id> attribute to my table and just order header's into <th> tag properly and when your page is ready call tablesorter for your table..!

One more good thing with it is that it comes with a companion Pager plugin which will add-up pagination to your listing.. Check-out this really good plugin if you need Pagination with Client-Side sorting for any of your application.
Thanks to New Wave Javascript - jQuery.

Tags: , ,

Radio-button with Checkbox behavior

Ever wanted Radio-button group which could be deselected once you click on any of the choice from given radio button group?

Then here is my simple jQuery plugin which you can use to make all your radio-buttons in the form behave like checkbox. Here by checkbox I mean to give Click to select and click-again to de-select kind of functionality.

How to use?

$(document).ready(function(){
    $(":radio").behaveLikeCheckbox();
});

For more details checkout live demo or goto jQuery plugin repository.

Update: Radio-buttons with Checkbox behavior - a jQuery Plugin 1.2.5

Tags: , , , ,

Online Face Recognition & Photo Organizer @ http://www.picporta.com

I would like to appreciate efforts of Mr Pulkit Gaur (Senior mate @ Meditab Software) for making Face Recognition possible and making it web enabled and gifting it as Photo Organizer to all of us..!

It's going to be the first service of its kind on the Web and I would like to congratulate Pulkit for his great hard work and efforts.

It's not just Online Face Recognition but it's with following buddies.

  • Smart Picture Organizer
  • Quick Photo Sharing & Printing
  • Multiple Face Recognition
  • and so on...

So now searching your photo albums with phrase like "Me & Mom" is possible.

It still is in it's beta version you can check it out on http://www.picporta.com and I wish it become publicly available asap.

Tags: , ,

HP Blackbird 002 DE LCi gaming PC with Price tag $6,200

It's an amazing piece of hardware.. I saw it and can't wait to post it on my blog.

For hardcore computer gamers, there is no such thing as too much power when it comes to their personal computer; there is only the question: How much can I afford? The Blackbird 002 DE LCi is definitely in the "money is no object" category. Sporting dual ATI Radeon X2900 XT video cards, each with 512GB of GDDR4 SDRAM, an Intel Core2 Extreme Quad-Core 3.0GHz QX6850 CPU, 2GB 1066MHz Corsair PC2-8500 SDRAM, three hard drives in a RAID array, and liquid cooling for the video cards and the CPU, this PC is a gamer's dream machine. And at about $6200, for many gamers, it will remain only a dream. HP loaned us a Blackbird 002 to review, and we just had to take a look inside. Read the rest of this entry »

Top free / open-source tools for MySQL Development / Administration

Here is list of great tools for PHP/MySQL

1. phpMyAdmin

PHPMyAdmin

phpMyAdmin is a tool written in PHP intended to handle the administration of MySQL over the Web. Currently it can create and drop databases, create/drop/alter tables, delete/edit/add fields, execute any SQL statement, manage keys on fields.

Most basic and must have tool and everyone is aware of it associated with PHP/MySQL and your shared web host must be providing you this tool to manage your databases on the web.

Type: Web based/OpenSource
URL: http://www.phpmyadmin.net

2. HeidiSQL

HeidiSQL

HeidiSQL is an easy-to-use interface and a "working-horse" for web-developers using the popular MySQL-Database. It allows you to manage and browse your databases and tables from an intuitive Windows® interface. Read the rest of this entry »

Tags: ,

Beginner’s Resources for PHP-MySQL Development

Sometimes developer’s don’t find the perfect startup environment for PHP development when they are in their initial stage. Setting up PHP with Apache could be difficult for beginner if he don’t know how to modify httpd.config or php.ini settings. In my initial stages I have installed PHP with IIS and then Apache and later even tried EasyPHP too. But EasyPHP has no release for PHP5, so that made me down. Never mind after some time I came across a PHP, MySQL and Apache package with which I fall in love. It is truly zero configuration installation to start PHP, MySQL development with Apache over any platform including Windows, Linux, Solaris, Mac OS X. The other good alternate to that is WAMP Server if you are using Windows for development.

XAMPP or WAMPSERVER both are good development environment for novice or experienced developers when want zero configuration LAMP/WAMP environment. You can even use it for production server with modifications in some of security measures and optimizing MySQL and PHP settings as per your server configuration (mainly memory). Read the rest of this entry »

Tags: , , , ,