Syling Custom Fields echo’s from from functions.php

How about just echoing out the needed syntax like that: echo ‘<div class=”custom-field”>’ . genesis_get_custom_field(‘instrument’) . ‘</div>’; You can also just use CSS and style the header.entry-header { //your sexy styles goes here } Since other elements inside are wrapped in their own elements and styled separately (I mean the actual H1 and meta data) … Read more

How can I hide my section title if there is no data in custom fields?

I would first loop over $lista and generate a new array of data that only has non-empty values. Now you can check $values to ensure there is data and output your title: function opening_hours_custom_fields() { global $post; if ( $lista = genesis_get_custom_field( ‘_happy_day’, $post->ID ) ) { $values = array(); foreach ( $lista as $value … Read more

remove_action conditionally for Custom Post Type – not working

I got it working in the end by using ‘template_redirect’ and changing the remove_action number from 8 to 1 🙂 // Remove ‘Genesis Co-Authors Plus’ author box and ‘filed under’ from custom post type add_action(‘template_redirect’, ‘lf_custom_cpt_display’); function lf_custom_cpt_display() { if ( is_singular( ‘local-bite’ ) ): { remove_action( ‘genesis_after_entry’, ‘gcap_author_box’, 1 ); remove_action( ‘genesis_entry_footer’, ‘genesis_entry_footer_markup_open’, 5 … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)