Archived

This topic is now archived and is closed to further replies.

  • 0

Hide author info in post clips

Question

Posted · Report post

How do I hide author, put show date and category information in clip style posts?

Share this post


Link to post
Share on other sites

5 answers to this question

Posted · Report post

the post-clips have static metabar options because it's a much smaller space but we can create a hook to add/change/remove whatever you want. Make sure you have the Base theme activated and add this to your functions.php file in Base ` add_action('pagelines_loop_clipmeta_end','custom_meta_clip'); function custom_meta_clip(){ <?php if(pagelines('byline_date')):?> <?php _e('on','pagelines');?> <?php the_time(get_option('date_format')); ?> <?php endif;?> <?php if(pagelines('byline_categories')):?> <?php echo '?·';?> <?php _e('in','pagelines');?>? <?php the_category(', ') ?> <?php endif;?> } `

Share this post


Link to post
Share on other sites

Posted · Report post

Thanks Adam, but does not work. Get a blank screen when I copy the above code in my base functions.php. Can't access the Control Panel nor the site. Thanks for your help. markus

Share this post


Link to post
Share on other sites

Posted · Report post

You'll want to delete functions.php and then re-upload the original and then simply use CSS to accomplish what you're after: `.metabar .sword, .post-author{display:none}` Thanks, Bryan

Share this post


Link to post
Share on other sites

Posted · Report post

Thanks Bryan. Author is now gone. But how do I ad Category information to clip style posts?

Share this post


Link to post
Share on other sites

Posted · Report post

@Markus I didn't try Adam's code, but it looks like the issue is just a couple of missing PHP tags. You could try this: ` function custom_meta_clip(){ ?> <?php if(pagelines('byline_date')):?> <?php _e('on','pagelines');?> <?php the_time(get_option('date_format')); ?> <?php endif;?> <?php if(pagelines('byline_categories')):?> <?php echo '?·';?> <?php _e('in','pagelines');?> <?php the_category(', ') ?> <?php endif;?> <?php } `

Share this post


Link to post
Share on other sites