Michael Posted October 2, 2015 Report Posted October 2, 2015 On the company address, if you put this: 123 Demo, Street name, Address, Town, zipcode It would output: 123 Demo, Street name, Address, Town, zipcode Not with the lines. a.daniello 1
a.daniello Posted October 2, 2015 Report Posted October 2, 2015 New line is stored in db, so, where is necessary, it should use a simple nl2br() php method. Where you think to use address in new way? Michael 1
Michael Posted October 2, 2015 Author Report Posted October 2, 2015 New line is stored in db, so, where is necessary, it should use a simple nl2br() php method. Where you think to use address in new way? Thank you mate life saver. <?php if( $system_company->address !='' ){ echo nl2br($this->Html->safe($this->Html->ifSet($system_company->address))); } ?>
Michael Posted October 2, 2015 Author Report Posted October 2, 2015 Where is this shown? Structure.pdt When I did it before it was in the line but with the code above it goes in the way you set it in the company settings
Tyson Posted October 2, 2015 Report Posted October 2, 2015 We don't show company address in the structure. I guess this is a custom change you've added? If so, then running it through nl2br wherever you're using it is the preferred solution. We wouldn't update the company address field to automatically display line breaks as HTML breaks otherwise. Michael 1
Michael Posted October 2, 2015 Author Report Posted October 2, 2015 We don't show company address in the structure. I guess this is a custom change you've added? If so, then running it through nl2br wherever you're using it is the preferred solution. We wouldn't update the company address field to automatically display line breaks as HTML breaks otherwise. Ah that's why nl2br works fine so perfect haha.
Tyson Posted October 2, 2015 Report Posted October 2, 2015 Sounds good. I'll close this feature request something we wouldn't do by default. Michael and ariq01 2
Recommended Posts