Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tordans/954928968279dfd8790a to your computer and use it in GitHub Desktop.
Save tordans/954928968279dfd8790a to your computer and use it in GitHub Desktop.
JavaScript um in der chip.de-Bestenliste Spalten zu löschen
// chip.de/bestenlisten/Bestenliste-Handys--index/detail/id/900/price/400/?f=0300002000010000400000000
$('th.header')
.css('position','relative')
.append('<DIV class="deleter" style="top:0;position:absolute;padding:5px;">x</DIV>');
$('.deleter')
.click( function() {
var $column_index = $(this).parent('th').index() + 1;
$('#mainTable tr').find('td:nth-child('+$column_index+'), th:nth-child('+$column_index+')').remove();
}
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment