Results 1 to 7 of 7

Thread: Memory Scroller

  1. #1
    Join Date
    Nov 2005
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Memory Scroller

    Wondering if you can insert images with a table etc. into the var memorycontent= instead of text?

  2. #2
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    I don't see why not. I'd do something like so:

    Code:
    var memorycontent='<nobr><img src="pic1.jpg"><img src="pic2.jpg"></nobr>'
    Just make sure to adjust:

    Code:
    var memoryheight="20px" //scroller height
    so that it is high enough to accommodate the image(s).
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  3. #3
    Join Date
    Nov 2005
    Location
    Oklahoma
    Posts
    16
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    How would you adjust the size of the jpg inside of the scroll bar instead of making the scroll bar bigger.

  4. #4
    Join Date
    Nov 2005
    Location
    Oklahoma
    Posts
    16
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Also how can you to and image plus text at the same time

  5. #5
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    To adjust the size of the image, resize a copy of it in an image program (bilinear resampling is usually the best for this). There are other ways but, this is truly the best method, especially if you are making your image smaller. After all other editing of images is complete, they should also be optimized for web presentation. There is a DD online utility for that if you've no optimizing software that can do a better job. This type of layout worked fine here for images with captions:

    Code:
    var memorycontent='<nobr><table><tr><td><img src="photo1.jpg"><br><span>caption</span></td><td><img src="photo2.jpg"><br><span>caption</span></td><td><img src="photo3.jpg"><br><span>caption</span></td></tr></table></nobr>'
    Images should be of the same height as each other and the 'var memoryheight' should be set to the image height + about 25px. I added this style section to the head of the page for good measure:

    Code:
    <style type="text/css">
    #memoryscroller td {
    text-align:center;
    font-family:verdana, arial, sans-serif;
    font-size:85%;
    }
    #memoryscroller td img {
    padding-bottom:2px;
    }
    </style>
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  6. #6
    Join Date
    Nov 2005
    Location
    Oklahoma
    Posts
    16
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    That works but it puts the image on top of the caption and not to the left or right of it. Any fix for this?
    Last edited by vermima; 12-04-2005 at 12:31 AM.

  7. #7
    Join Date
    Nov 2005
    Location
    Oklahoma
    Posts
    16
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I figured it out. Thanks for your help.

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
  •