No line breaks in custom fields

This topic contains 6 reply and 3 voices, and was last updated by paperweight 10 years, 10 months ago
Viewing 6 Posts - 1 through 6 (of 6 total)
Author Posts
June 8, 2013 at 5:16 pm 4674
paperweight Hey, Thanks for a great plugin. However, we've add custom fields but the line breaks won't apply. Any thoughts on what we are missing? http://2013.studentkrubb.se/chickenalaking/ Thanks!
June 9, 2013 at 1:32 pm 4692
Tareq Hasan Tareq Hasan

How are you printing the custom field values? Maybe using the nl2br function will work.

ex: <?php echo nl2br( get_post_meta( $post->ID, 'meta_key', true ) ); ?>

June 9, 2013 at 2:43 pm 4693
paperweight paperweight

I have this issue too. For example I have a textarea and when users use line breaks and click save it is all saved without the linebreaks. The nl2br would not assist in that situation since this is not yet outputting — it is instead just trying to save the original info.

June 9, 2013 at 4:56 pm 4698
Tareq Hasan Tareq Hasan

I’ve just tested, I’ve used a custom field textarea field. The line breaks was saving fine and I can see the line breaks in the admin panel and in frontend edit post area too. So that should be working.

June 9, 2013 at 5:53 pm 4704
Joakim-sb Joakim-sb

Hey,

It seems as if you are posting from within the wp-admin instead of using the frontend posing it ignores the line breaks.

June 9, 2013 at 7:20 pm 4706
paperweight paperweight

I have had this issue with various WPUF versions (not only wedevs version but also the original). I even hired an outside developer to help develop a customized version and this was one of the bugs I wanted him to fix. it does not happen all the time, but I estimate about 50% of the time it happens, so it is difficult to troubleshoot.

It usually seems to break when using Opera, though I have had issues also with Firefox. I have not seen the issue with IE or Maxthon.

June 9, 2013 at 7:21 pm 4707
paperweight paperweight

We are posting from the frontend by the way, not from the wp-admin backend….

Viewing 6 Posts - 1 through 6 (of 6 total)