Page 1 of 1

row break from textarea

Posted: Tue Jan 06, 2015 4:35 am
by skip
Im change my admin fax field to textarea successfuly but now got problem on frontpage .text is not shown exatcly as I enter in textarea -system does not recognize new line for example if I enter in my textarea:

some
text

it will show:
some text

What exatcly impact on textarea formating

thanx

opencart version 2.0.1.1

Re: row break from textarea

Posted: Wed Jan 07, 2015 6:10 pm
by opencarthow.com
skip wrote:Im change my admin fax field to textarea successfuly but now got problem on frontpage .text is not shown exatcly as I enter in textarea -system does not recognize new line for example if I enter in my textarea:

some
text

it will show:
some text

What exatcly impact on textarea formating

thanx

opencart version 2.0.1.1
It seems that OpenCart strips format of your text. Could you take some screenshots about the problem so I can take a look at it closer?

Re: row break from textarea

Posted: Wed Jan 07, 2015 7:44 pm
by skip
Thank you opencarthow.com - I was solved problem in meanwhile:
There is funkction in controller for such problems "nl2br"
so change:
'fax' => $location_info['fax']
to:
'fax' => nl2br($location_info['fax'])

Re: row break from textarea

Posted: Thu Jan 08, 2015 12:03 am
by opencarthow.com
skip wrote:Thank you opencarthow.com - I was solved problem in meanwhile:
There is funkction in controller for such problems "nl2br"
so change:
'fax' => $location_info['fax']
to:
'fax' => nl2br($location_info['fax'])
Glad to hear that you figured out the problem :)