Fix for Fix for jQuery to change banner on page

  1. Drupal.behaviors.setBanner = function (context) {
  2.     var img = {
  3.         '/content/services': 'Banner2.jpg'
  4.     }[location.pathname] || Banner1.jpg';
  5.    
  6.    $("td#header").css("background","url(/sites/all/themes/mytheme/images/" + img + ") no-repeat");
  7. };

Submit Fix

Any tags you'd like to associate with your code, delimitered by commas (example: Views, CCK, Module, etc).
Select the syntax highlighting mode to use.