dcsimg
www.webdeveloper.com
Results 1 to 6 of 6

Thread: Wrapping IFRAMES

  1. #1
    Join Date
    Dec 2002
    Posts
    32

    Wrapping IFRAMES

    I have an IFRAME in my page, however I want to wrap the text in it. How do I do this?

    Thanks

  2. #2
    Join Date
    Nov 2002
    Posts
    984
    Normally the text in an iframe will auto wrap when the text doesn't fit on one row, just like on a normal page.

    If it's not doing that it's becuse you have done something to prevent it wraping normally.

    To know what that is however requires that you leave a link to your site.

  3. #3
    Join Date
    Dec 2002
    Posts
    32
    I have included the script. You need to open EDITOR.HTML and see the IFRAME. Thanks
    Attached Files Attached Files

  4. #4
    Join Date
    Nov 2002
    Posts
    984
    Ok, this is considerably more complex then you first description of your page.

    You are not loading an iframe, you seem to be trying to make webbased editor and the code is prettyu banged up.

    For starters, this is what your iframe looks like

    <font size="2" face="Verdana, Helvetica"></font>

    That is VERY far from how a HTML page should look like, which is something like this

    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <meta http-equiv="Content-Script-Type" content="text/javascript">
    <meta http-equiv="Content-Style-Type" content="text/css">
    <title></title>
    </head>
    <body>

    </body>
    </html>

    However are you sure you are not really looking for the <textarea> tag instead of an <iframe> ?

    Also your JavaScript is broken and only works on IE.

  5. #5
    Join Date
    Dec 2002
    Posts
    32
    Of course it will only work in IE. It uses DOM.

    Anyway I use an IFRAME because it can be used to display HTML and is what you are told to do when you create a content manager.

    Thanks anyway

  6. #6
    Join Date
    Nov 2002
    Posts
    984
    Originally posted by ollmorris
    Of course it will only work in IE. It uses DOM.
    JFYI

    DOM = Document Object Model of which there is a perfectly fine standards crossbrowser version.
    http://www.w3.org/DOM/

    Apart from that one there is an old IE proprietary format just as there are other old proprietary format for eg NS 4.x.

    In short, all JS browsers have a DOM of some sort.
    If you can't get your JS to work in Netscape 6+ it's generally becuse you are stuck in the late 1990-ies coding with a browserspecific proprietary DOM instead of a modern one that works crossbrowser.


    In any case, your page linebreaks just fine in IE 6.01 when I tried it.
    However it will only linebreak if there actually IS somewhere to linebreak (that means a space). If you have 200 chars in one row and no space the row will be minimum 200 chars long.

    The reason i suggested textarea before is that IE has a special property in were it actually makes linebreaks even in compact (no space) text if entered in textareas.
    Last edited by Stefan; 01-03-2003 at 03:21 AM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



Recent Articles