I have this bit of code:
<?php $fields = get_acf(); echo $fields->event_address; ?>
This outputs an address from a text area box in WordPress. In that box I’ve written the address like this:
Address line 1,
Address line 2,
Address line 3
With the variable at the top it outputs all the info on one line (it doesn’t recognise the address is over 3 lines), is it possible to do something clever to get it to display over 3 lines.
I know I could quite easily add more fields to WordPress to show the 3 lines but I’d like something a bit more neat than that!
You could try solving this with pure css:
The paragraph behaves like the
<pre>tag afterwards, breaking visually at line-breaks.