Results 1 to 4 of 4

Thread: everything is inline?

  1. #1
    Join Date
    Feb 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default everything is inline?

    1) Script Title:
    :: Text and Image Crawler

    2) Script URL (on DD):
    http://www.dynamicdrive.com/dynamici...wler/index.htm

    3) Describe problem:
    I try to make it short.
    Here is a easy HTML code
    <table border="1" width="100px">
    <tr>
    <td width="100px">This is a test for the forum.
    </td>
    </tr>
    </table>

    Without the use of the script, this displays:
    This is a test
    for the forum

    with a border around the text (border=1).
    There is an automatic wrap (Because of the fixed width).

    The same HTML code in the DIV (class="marquee" id="mycrawler">) of the script, will display:
    This is a test for the forum

    There is no wrap.
    Everything is inline.
    It is a bug? an unexpected behavior? a limitation of the script?

    The idea is to display a set of pictures, that scroll from right to left, and with a description under the picture.
    As the description could be a bit long, I would need to fix the width of each picture/description, so it looks like:
    PICTURE1 PICTURE2
    This is a test This is a test
    for the forum for the forum

    Which is nicer that what I have now with the script:
    PICTURE1 PICTURE2
    This is a test for the forum This is a test for the forum
    (description could be longer!!)
    It works fine with another scrit on dynamicdrive (:: Cross Browser marquee), that's why I am wondering whether it is a bug or not.

    "Text and Image Crawler" has more features that "Cross Browser marquee" that's why I am wondering if it could be improved or not.

    Thanks a lot
    Rod

  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

    You have to specify white-space normal for the td's, as the crawler itself is set to white-space nowrap, ex (for use in a stylesheet):

    Code:
    td {
    white-space: normal;
    }
    - John
    ________________________

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

  3. #3
    Join Date
    Feb 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    thanks you John,
    actually I tested with white-space: wrap; !! instead of normal;

    I guess it will work with what you say.

    On another hand I decided to not use this script when I realized that it is too much CPU consuming (100%!!).
    I use the standard MARQUEE which does not consume more than between 5-15%.
    BTW it is part of CSS3 now.
    There is less feature than the script, but when I balance features and performances...

    Thanks a lot anyway, I 'm sure it will hekp others.

    Rod

  4. #4
    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 feel sorry for your CPU, mine takes like about 20%, for 3 crawlers on one page. I think it may depend upon the browser, OS, and CPU, as well as the content of the crawler.

    The marquee tag might be more CPU intensive for certain combinations of these.

    But if the marquee tag works out for you, that's fine by me. It probably can be made (via a javascript assist) to behave somewhat like crawler, at least in some browsers. But that might boost the CPU requirement.
    - John
    ________________________

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

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
  •