I am using struts 2. I have the following class
<code>
public class test1 {

private String body;

public void setBody(String body){
        this.body = body;
} 

public String getBody(){
        return body;
}

}
</code>

I have a jsp with a textarea whose name is body. The text contained in
body is newline then some text. The form is then posted to an action
that then writes it away to the database. If I then go back to view the
same page the newlline character has been removed. The text is being
trimmed by struts before it is displayed in the textarea.

-----Original Message-----
From: Antonio Petrelli [mailto:[EMAIL PROTECTED] 
Sent: 17 May 2007 11:00
To: Struts Users Mailing List
Subject: Re: newline being ignored

2007/5/17, David Harland <[EMAIL PROTECTED]>:
> I have an object with String variable body. In the body is a newline 
> character then some text. When this is being posted the newline seems 
> to be being trimmed is there any way to stop this please?

Posted? Where?
And what are you using? Struts 1 or Struts 2?

Antonio

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


- ------
ML {UFI}

______________________________________________________________________
Ufi Limited 
Registered in England No.  3980770 
Registered Office:  Dearing House, 1 Young Street, Sheffield, S1 4UP 

learndirect Solutions Ltd 
Registered in England No. 5081669 
Registered Office:  Dearing House, 1 Young Street, Sheffield, S1 4UP 

UFI Charitable Trust 
Registered in England No.  3658378 
Registered Charity No.  1081028 
Registered Office:  Dearing House, 1 Young Street, Sheffield, S1 4UP 

This email has been scanned by the MessageLabs Email Security System.

______________________________________________________________________

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to