Results 1 to 4 of 4

Thread: Image thumbnail viewer

  1. #1
    Join Date
    Jun 2011
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Image thumbnail viewer

    1) Script Title: IMAGE THUMBNAIL VIEWER

    2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex4/thumbnail.htm

    3) Describe problem: I have this viewer working on my site and it works a treat, However can I add text better than simply using the "title" attribute of the <a href>.

    I would like to be able to control format and perhaps have something inside a <table> below the image so that I can have Name, Title Job Description, below the image of the person, and be able to add <classes> to the text to make it look nice.

    You can see how far I have got here - still roughing it out.

    http://albionhousehairsalon.co.uk/im...argetest3.html

    Thanks, Simon.

  2. #2
    Join Date
    Aug 2009
    Location
    utf-8
    Posts
    205
    Thanks
    4
    Thanked 7 Times in 7 Posts

    Default

    If you want to add content under the image, try using ThickBox iframe
    http://jquery.com/demo/thickbox/

    Let me know if you want an example, need more help, etc..

  3. #3
    Join Date
    Jun 2011
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    OK, thanks, I'll have a look at this.

    It looks like it completely replaces the code I am using - is this correct?

  4. #4
    Join Date
    Jun 2011
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Until I have a chance to suss out Thickbox etc, can you help me with this problem.

    I have some javascript which allows me to enlarge a picture and display its corresponding text by clicking a thumbnail of the picture.

    It looks like
    Code:
    function LoadGallery(pictureName,imageFile,titleCaption,captionText,titleText,textText,titleJob,jobText,titlePricelist,pricelistText)
    {
      var picture = document.getElementById(pictureName);
      if (picture.filters)
      {
        picture.style.filter="blendTrans(duration=1)";
        picture.filters.blendTrans.Apply();
      }
      picture.src = imageFile;
      if (picture.filters)
      {
        picture.filters.blendTrans.Play();
      }
      document.getElementById(titleCaption).innerHTML=captionText;
      document.getElementById(titleText).innerHTML=textText;
      document.getElementById(titleJob).innerHTML=jobText;
      document.getElementById(titlePricelist).innerHTML=pricelistText;
    
    }
    I pass variables into the script using the <div> id
    Code:
    <div class="Text_Content" id="TeamGalleryPrices">Click on the thumbnails to find out more about the team at albion house</div>
    However whan I call this function and attempt to add a hyperlink to the last of these variables - it doesn't work.

    The code I use to call the variables in is as follows:

    Code:
    <a href="#_self" onclick="LoadGallery('TeamGallery', 'http://www.albionhousehairsalon.co.uk/images/theteam_helen_lg.gif', 'TeamGalleryCaption','Helen','TeamGalleryText','Some text.....','TeamGalleryRole','Director','TeamGalleryPrices','<a href=\'http://www.dynamicdrive.com\'> Goto Dynamic Drive</a>')"><img src="http://www.albionhousehairsalon.co.uk/images/theteam_helen_thumb.gif" width="90" height="61" /></a>
    I have the basis of this code working here:
    http://albionhousehairsalon.co.uk/al...am3.html#_self

    Tried everything... so my code must be wrong?

    Thanks, Simon.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •