This is the last part of this project, thanks to all who've helped with syntax correction on other parts. I'm using the tablesorter plugin for jQuery. Basically, what I want to accomplish is for my custom sort function to pick a table header based on whether or not it has a class, namely "SortableHeader". It then has to decide what metadata parser to add to the header of that particular column based on the data in that column. I've taken the more complex approach and decided to take a sample of the data from a single cell( say the first row of the column) and compare it to different patterns, or regular expressions, the sorter will then add the proper metadata parser based on the comparison result, e.g. if it matches the date pattern, the sorter will add the date parser, if it matches the URL pattern, it adds the URL parser, etc. I have two issues: This is the last part of this project, thanks t