web design, England, Britain, UK, belgium
 
Ulti Clocks content

Separate links for Briask ImageSlideShow module images Part 2

JOOMLABOTTOM sand How to link any Joomla ImageSlideShow module images to any url. The Joomla ImageSlideShow module from briask.com is an excellent and simple image gallery which shows any images from a designated folder.
picurl, case, picurlx, break, image, echo, url, number, images, file, params, add, mod, line, jpg, open, briaskiss, links, link, individual, module, imageslideshow, switch, editor, lines, replace, modules, preg, briask, ditch, underneath, folder, like, rename, allows, sequence, following, comment, hack, excellent

Home Joomla - VirtueMart Joomla & VM How To's Separate links for Briask ImageSlideShow module images Part 2

Mon

14.

Dez

Separate links for Briask ImageSlideShow module images Part 2

  • Joomla 1.5

The ImageSlideShow module from briask.com is an excellent and simple image gallery which shows any images from a designated folder and have one link from the images. Clients (and I see on Briask's own forum) have asked whether it would be possible to have individual links to individual images.
This hack allows you to link any image to any url.

Separate links for ImageSlideShow module First rename your images with a sequence of numbers like so -
  • image1.jpg
  • image2.jpg
  • image3.jpg
etc...

Upload them to your image folder for the ImageSlideShow module.

Open up the file modules/mod_briaskISS/mod_briaskISS.xml in your editor and go to line 55 and add these lines underneath. Add as many new input boxes as you need for your links. -->
 
<param name="URL1" type="text" size="100" default = "http://www.joomla.org" label="URL1"  description = "URL1 to link to when Slideshow image is clicked."/>
 
<param name="URL2" type="text" size="100" default = "http://www.joomla.org" label="URL2"  description = "URL2 to link to when Slideshow image is clicked."/>
 
<param name="URL3" type="text" size="100" default = "http://www.joomla.org" label="URL3"  description = "URL3 to link to when Slideshow image is clicked."/>
 
<param name="URL4" type="text" size="100" default = "http://www.joomla.org" label="URL4"  description = "URL4 to link to when Slideshow image is clicked."/>
 

Separate links for each ImageSlideShow module image The ImageSlideShow module backend will look like this now.



Now open up the file modules/mod_briaskISS/mod_briaskUtility.php in your editor and go to line 221 and add these lines underneath. These just fetch the new url parameters. -->
 
$picURL1 = $params->get('URL1', 0);
  $picURL2 = $params->get('URL2', 0);
  $picURL3 = $params->get('URL3', 0);
  $picURL4 = $params->get('URL4', 0);
 

Then down to line approx. 347
 
echo '<li><a href="'.$picURL.'"><img src="'.$picDir.'/'.$file.'" alt="'.$picTitle.'" /></a></li>';
 

Comment this out and add the following ->
 
//echo '<li><a href="'.$picURL.'"><img src="'.$picDir.'/'.$file.'" alt="'.$picTitle.'" /></a></li>';
      $number = preg_replace("/[^0-9]/", '', $file); // ditch anything that is not a number
 
      switch ($number) {
      case 1:
       $picURLx = $picURL1;
        break;
 
        case 2:
       $picURLx = $picURL2;
        break;
 
        case 3:
       $picURLx = $picURL3;
        break;
 
        case 4:
       $picURLx = $picURL4;
        break;
        }
 
 
 
 
       echo '<li><a href="'.$picURLx.'"><img src="'.$picDir.'/'.$file.'" alt="'.$picTitle.'" /></a></li>';
 
and again for the Case 2 (open in new window)
 
echo '<li><a href="'.$picURL.'" target="_blank"><img src="'.$picDir.'/'.$file.'" alt="'.$picTitle.'" /></a></li>';
 
Change to..
 
//echo '<li><a href="'.$picURL.'" target="_blank"><img src="'.$picDir.'/'.$file.'" alt="'.$picTitle.'" /></a></li>';
      $number = preg_replace("/[^0-9]/", '', $file); // ditch anything that is not a number
 
      switch ($number) {
      case 1:
       $picURLx = $picURL1;
        break;
 
        case 2:
       $picURLx = $picURL2;
        break;
 
        case 3:
       $picURLx = $picURL3;
        break;
 
        case 4:
       $picURLx = $picURL4;
        break;
        }
 
 
 
 
       echo '<li><a href="'.$picURLx.'" target="_blank"><img src="'.$picDir.'/'.$file.'" alt="'.$picTitle.'" /></a></li>';
 



Now the individual images will link to the required links.


Add this page to your favorite Social Bookmarking websites
Digg! Reddit! Del.icio.us! Mixx! Free and Open Source Software News Google! Live! Facebook! Slashdot! Technorati! StumbleUpon! Spurl! Newsvine! Furl! Fark! Yahoo! Netvouz! Mister-Wong! RawSugar! Ma.gnolia! Squidoo! DZone! Swik!
Zuletzt aktualisiert am Samstag, 26. Dezember 2009 um 00:35 Uhr Read : 2691 times
 
Comments (3)
Open in new window
3 Samstag, 26. Dezember 2009 um 00:31 Uhr
GJC (admin)
You need then to apply the hack to the Case 2
~ line 334

Have added above in the article..
correction
2 Freitag, 25. Dezember 2009 um 20:00 Uhr
Pete
The word 'links' is missing above. Should read "none of the links I inserted"
Image slide show new window select dysfunction
1 Freitag, 25. Dezember 2009 um 19:58 Uhr
Pete
Your hack works great however when I choose the option to open in new window, none of the I inserted are seen by the script. Only the baseurl is applied to all images.

Add your comment

BoldItalicUnderlineStrikethroughSubscriptSuperscriptEmailImageHyperlinkOrdered listUnordered listQuoteCodeHyperlink to the Article by its id
Very HappySmileWinkSadSurprisedShockedConfusedCoolLaughingMadRazzEmbarrassedCrying or Very SadEvil or Very MadTwisted EvilRolling EyesExclamationQuestionIdeaArrowNeutralMr. GreenGeekUber Geek
Your name:
Titel:
Comment:

Latest Articles

Paypal Donation

If you use this module on your site please donate a small amount.
Any donation amount appreciated.

VM Live Product Search

Recommended Reading

For those interested in extending there knowledge of Joomla! & VirtueMart Packt Publishing has an excellent range of help & how to books.
Listed below are some I can recommend.
Simply click on the images to be taken directly to their web shop.

Learning Joomla! 1.5 Extension Development Learning Joomla! 1.5 Extension Development
by Joseph L. LeBlanc.
Read the review
Joomla! E-Commerce with VirtueMart Joomla! E-Commerce with VirtueMart
by Suhreed Sarkar.
Read the review
Joomla! Web Security Joomla! Web Security
by Tom Canavan.

Mastering Joomla! 1.5 Extension and Framework Development Mastering Joomla! 1.5 Extension and Framework Development
by James Kennard.

Joomla! Template Design: Create your own professional-quality templates with this fast, friendly guide Joomla! Template Design: Create your own professional-quality templates with this fast, friendly guide
by Tessa Blakeley Silver.

JOOMLABOTTOM



Separate links for Briask ImageSlideShow module images Part 2



How to link any Joomla ImageSlideShow module images to any url. The Joomla ImageSlideShow module from briask.com is an excellent and simple image gallery which shows any images from a designated folder.


picurl, case, picurlx, break, image, echo, url, number, images, file, params, add, mod, line, jpg, open, briaskiss, links, link, individual, module, imageslideshow, switch, editor, lines, replace, modules, preg, briask, ditch, underneath, folder, like, rename, allows, sequence, following, comment, hack, excellent