Custom Fields displaying in single line

Probably not the best solution, but why don’t you try the following: while ( have_posts() ) : the_post(); ?> <div><?php $key_name = get_post_custom_values ($key = ‘country’); echo ‘Country : ‘, $key_name[0]; ?> </div> <div><?php $key_name = get_post_custom_values ($key = ‘status’); echo ‘Status : ‘, $key_name[0]; ?> </div>

How to show the contants in front end same as visual editor with space / linebreak?

When you use get_the_content() to get your content, you need to apply filters to it to output with formatting. apply_filters(‘the_content’, $content); If you don’t need to do anything with the content before outputting it, you can replace your line $content = get_the_content(‘Read more); print $content; with just the_content(); For reference see apply_filters() and get_the_content() in … Read more

How to break line / add to ADMIN menu

<br> tags are not the solution to the problem that you were hoping they would be. Menu labels were never intended to contain arbitrary HTML. HTML does slip through in places, but this appears to be a bug and is inconsistent. For Post Types No. You can’t. $menu[ $ptype_menu_position ] = array( esc_attr( $ptype_obj->labels->menu_name ), … Read more

Pasting code into WordPress post – LFs being eaten

This almost certainly appears to be a Google Chrome issue (though the bug is still probably within WordPress, since Chrome does preserve all tabs and linebreaks when pasting into the Paste Text or Paste from Word areas, so Chrome is not itself stripping out the linebreaks.) I’m recommending we close this cause it probably doesn’t … Read more