Skip to main content

Homescreen Teaser Disabler

Library Catalog Search Bar stuff

Put this in the advanced Head section to disable the POC instance of a teaser. Make sure to put the exact name of the teaser/s in here:
<script>
// jquery hack to remove links in the following homepage teasers
$(function() {
  if ($('.homepage').length == 0) return;
  $.each(['Teaser1', 'Teaser2, 'Teaser3'], function(i, text) {
    var elem = $('.poc-instances-main-content .poc-instance:contains("' + text + '") a');
    elem.find('.call-to-action').remove();
    var html = elem.html();
    elem.replaceWith("<div class='inner'>" + html + "</div>");
  })
});
</script>