How to display multi-line text with 'title' tag

Discussion in 'HTML & Website Design' started by bzemer, Jan 20, 2009.

  1. #1
    Hello,
    I'm using the 'title' tag to display information about an image.
    But i want to write multi-line text.
    When i use this code:
    <img src="http://someimage" title="
    blah blah blah
    yada yada yada
    ">
    Code (markup):
    I get the text: "blah blah blahyada yada yada".
    How can i show multi-line text correctly?

    thank ahead.
     
    bzemer, Jan 20, 2009 IP
  2. mapAffiliation

    mapAffiliation Peon

    Messages:
    17
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    In general the answer is : this is not possible.
    There is no strictly difined restriction how to display attribute "title" ( www .w3. org/TR/html4/struct/global.html#h-7.4.3 )
    So browsers display it different ways.
    You will have line break for attribute "title" in IE, but FF will deside itself where to break the line if it's too long.
     
    mapAffiliation, Jan 20, 2009 IP
  3. bzemer

    bzemer Peon

    Messages:
    5
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    I see, is there any other way i can get a multi-line tool tip for an image (or link or anything), without using code (java etc.).
    I want to use this in forum posts and i can't use coding.
     
    bzemer, Jan 20, 2009 IP
  4. mapAffiliation

    mapAffiliation Peon

    Messages:
    17
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    I think there is no othrer way than to use JavaScript if you need proper formatting :(
     
    mapAffiliation, Jan 20, 2009 IP
  5. bzemer

    bzemer Peon

    Messages:
    5
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    OK, thanks for all your help :)
     
    bzemer, Jan 20, 2009 IP