How to style a byline field in an article content type? There might be a simple answer to this but it's driving me crazy. I'm working on a template for an article node and I want the byline to display this way:


  By Author Name


I don't want to change the field label in the web form, so I just want the "By" to be inserted through the node template. No matter what CSS styling I use, the byline field always displays like this:


  By
  Author Name


Is there a way to get the label and field to show up inline?

Here's the PHP I'm using in the template:

&lt;div class="newsbyline"&gt;
  &lt;?php print t('By'); ?&gt; &lt;?php print render($content['field_newsbyline']); ?&gt;
&lt;/div&gt;


Setting the "newsbyline" &lt;div&gt; to inline doesn't seem to be working.
It would be helpful to see the markup that surrounds the newsbyline field. I'm guessing there's a div or some other element around field_newsbyline that's a block element by default. If you change the CSS for that element to display: inline that may solve the problem.

Alternatively, if the above code is in your node template, you could adjust the markup in the field template instead: 


Copying field.tpl.php from the base theme you're using or from Drupal core's /modules/field/theme/ into your theme
Rename it field--field-newsbyline.tpl.php (assuming field_newsbyline is the machine name of your field)
Edit that template to add &lt;?php print t('By'); ?&gt; in the appropriate spot.


By making the change in the field template, you should be able to get your code inside the wrapper div, rather than having it outside.