http://cjhhotels.com/infotech

Fixing Joomla! 1.5 Banners Print E-mail
Written by Julian Lilio   
Saturday, 05 July 2008

Not all banners are bad. For example, you want to use them to show different images of your organization on the corporate website. However, some users tend to be paranoid about these banners that anti-virus companies came up with ways how to block these banners from showing on websites visited. In my case, while developing our intranet site, the image gets replaced by a 1x1pixel .gif image. It was very frustrating at first but with some research, I was able to find the solution. I first saw it here .

Actually, there are two ways how to go about it.

First is to inform each of your users to remove the */banners/* from the list of banned directories. You wouldn't want this of course since you don't have control of all your viewers, right? Still here's an example when using Kaspersky just to make everything clearer so you wouldn't just blame the company who provided yo with your security software solution for a voodoo work:

Image 

Second is to do it in your Joomla! code.

To override the anti-banner effect of modern security software (e.g., Norton, Kaspersy, etc.) on your Joomla! installation, perform the following steps:

1) Go to the images directory of your Joomla! installation
2) Rename the banners folder to anything (e.g., show)
3) Go to administrator/components/com_banners/controllers directory
4) Create a backup copy of the original banner.php (e.g., renamed banner.old)
5) Open banner.php for editing
6) Change the line $directory = '/images/banners'; to $directory = '/images/show';
7) Go to modules/mod_banners directory
8) Create a backup copy of the original helper.php (e.g., renamed helper.old)
9) Open helper.php for editing
10) Replace all instances of images/banners with images/show

 

Now at least the once not showing http://localhost/joomlasite/images/banners/osmbanner2.png is now visible through  http://localhost/joomlasite/images/show/osmbanner2.png even if your anti-banner is turned on. The next hurdle is to check what else are affected in code to make the banners show on the module position. Half of the problem solved anyway... :-)

 

Finally, make sure that either you don't have a Custom Banner Code defined in your banner details or that your custom code will need to point to a valid image location which is also not blocked by your anti-banner.

 

That should be perfect. It worked for me. :-)

 

Cheers!

» 1 Comment
1"Image Slider"
at Saturday, 05 July 2008 15:51by julian.lilio
if you do not need a lot of images to show for your banner requirements, one alternative is to use the Image Slider for J!1.5 from You! Joomla. You can include 10 slides on the module. I think this is just enough for my needs at the moment. :-)
» Post Comment
Email (will not be published)
Name
Title
Comment
 remaining characters
 
< Prev