if (location.href.indexOf('forum/1000104') !== -1) {
    var ticket_table = $('table.posts:has(th:contains(Personal)):first tbody'),
    colspan = ticket_table.find('tr:contains(Title):first th').length,
    num_categories = [["interviews", 0], ["applications", 0], ["support_sheep", 0]];

    ticket_table.find('tr:contains(Title):first').after("<tr id='interviews'><td style='text-align: center; font-size: 150%; font-weight:bold' colspan='" + colspan + "'>Interviews</td></tr><tr id='applications'><td style='text-align: center; font-size: 150%; font-weight:bold' colspan='" + colspan + "'>Applications</td></tr><tr id='support_sheep'><td style='text-align: center; font-size: 150%; font-weight:bold' colspan='" + colspan + "'>Support Tickets</td></tr>");

    $('a[href*=topic][title*=Start Date]').each(function () {
        var desc_ele = $(this).parent().find('div.description'),
            tr = $(this).closest('tr'),
            desc = desc_ele.text();

        if (desc.match(/(community|support)/i) && !/interview/i.test(desc)) {
            desc_ele.css('color', RegExp.$1.toLowerCase() === 'support' ? '#6479B7' : '#009900');
            tr.insertAfter('#applications');
            ++num_categories[1][1];
        } else if (/interview/i.test(desc)) {
            if (desc.match(/(community|support)/i)) {
                desc_ele.css('color', RegExp.$1.toLowerCase() === 'support' ? '#6479B7' : '#009900');
            }
            tr.insertAfter('#interviews');
            ++num_categories[0][1];
        } else {
            ++num_categories[2][1];
        }
    });

    $.each(num_categories, function () {
        if (this[1] === 0) {
            $('#' + this[0]).remove();
        }
    });
}
