Links

Lists

Latest Updates

Ruby On Rails List
Python list
Advanced Java
The JavaScript List
Apache Users
Full Disclosure
Linux Security

Search the archives!


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Javascript] return \n


  • From: liorean at gmail.com (liorean)
  • Subject: [Javascript] return \n
  • Date: Tue Dec 19 11:41:31 2006

On 19/12/06, Diego Chagastelles <dchagastelles@xxxxxxxxx> wrote:
> I want to get the value of a textarea element. I get the value when the user
> press Enter (Return Key). The problem is that when I do this, the textarea
> value comes with "\n" in the end. I know its there, how can I strip this
> out?

string.replace(/\n$/,'');
-- 
David "liorean" Andersson