Thread: Text wrap

    #1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2012
    Posts
    2
    Rep Power
    0

    Text wrap


    Hi guys.

    I'm new to the JavaScript coding and I hope you can help me, I'm searching for a few hours how to make a script, which has to disable text wrapping. Is there a function or a tutorial you can give me?

    Thanks in advance
  2. #2
  3. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    May 2012
    Posts
    13
    Rep Power
    0
    You can do that with CSS:

    http://www.w3schools.com/css/tryit.asp?filename=trycss_text_white-space

    To enable or disable it by script:

    http://www.w3schools.com/jsref/prop_style_whitespace.asp
  4. #3
  5. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2012
    Posts
    2
    Rep Power
    0
    Hi NbrSix and sorry for the late response. Been busy -.-
    Now, about the text wrapping. Let me explain with more details. There is a site (it's private, can't give you link to sign up ) where if I make a post with FF, IE, Opera or any other browser (except Chrome) the data is sent like this :
    asd asd asd asd asd asd
    This is the right way and the way I want it to be.

    But with Chrome it goes like this :
    asd asd asd asd
    asd asd ads

    I checked the elemnts and found this :
    Code:
    <textarea name="descr" rows="10" cols="80" wrap="physical" onkeydown="textCounter(this.form.descr,this.form.remLen,15000);" onkeyup="textCounter(this.form.descr,this.form.remLen,15000);">
    </textarea>
    When I remove the "wrap=physical" attribute, the data was send fine. So, I started searching for add-ons which can inject JavaScript/CSS in to the current page. But I can't write down properly the code in to the add-on so that the browser can send the data the way it's supposed to be. Can you give me an advice?

    Thank you for trying to help me!

IMN logo majestic logo threadwatch logo seochat tools logo