I have 2 similar lines of code, the first one works OK but the second is not.
This one works ok and displays the title within the <li></li>
$output .= '<li>' . the_title() . '</li>';
This one returns an empty <li></li> and displays the result on top of the page
$output .= '<li>' . the_field('price') . '</li>';
the_field('price') is a custom wordpress field which i've created by using "Advanced Custom Fields" plugin. Here is the documentation of the plugin on how to output the data http://www.advancedcustomfields.com/resources/field-types/select/
the_field? A PHP function ? Where is it declared ? Please give more code (PHP, HTML) in order to give you a better answer - MatRtthe_field(price). You'll need to edit your answer with the declaration of that function to get real help. - JakeParisthe_fieldis a standard Wordpress function, and the question is tagged as being a Wordpress question... - Matt Browne