added old code for js ad placement;