Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #1360649

    Hello,
    how do i make the custom field “adress” visible below the content of a blogpost?
    – I will not use any plugins
    – i have a child theme in charge

    kind regards
    Eva Simone

    #1360703

    Hey evas49,

    I’m not sure I understand your question or problem, could you try to explain what you are looking to achieve a bit further please?

    Best regards,
    Rikard

    #1360799

    Hello,
    I already did:
    “How do i make the custom field “adress” visible below the content of a blogpost?”

    or:
    How do i make any given CF visible in the content of a blogpost?

    What is a custom field?:

    https://kriesi.at/support/search/?bbp_search=Custom+Fields

    Eva Simone

    #1360801

    Hello @guenni007 or @ismael
    can you please tell me where in loop-index.php i have to place the code to get my CFs echoed?
    <?php echo get_post_meta($post->ID, 'adress', true); ?>
    (unfortuately there are no good comments which makes a normaly very easy thing quite complicate)

    I followed exactly @yigit s advice here but all i got was “Call to undefined function the_field()”:
    https://kriesi.at/support/topic/displaying-custom-field-on-blog-post/

    This does also not work:

    echo '<h2>'; 
    get_post_meta($post->ID, 'adress', true);
    echo '</h2>';

    It simply shows nothing although the CF “adress” exists and is filled with data.

    kind regards
    Eva Simone

    • This reply was modified 2 years, 3 months ago by evas49.
    • This reply was modified 2 years, 3 months ago by evas49.
    #1360825

    Hi Eva,

    Please edit loop-index.php file on your child theme and find line 569

    		echo '<div class="post_author_timeline"></div>';
    		echo av_blog_entry_markup_helper( $current_post['the_id'] );
    
    		echo '</article>';

    and change it to following

    		echo '<div class="post_author_timeline"></div>';
    		echo av_blog_entry_markup_helper( $current_post['the_id'] );
    		echo '<p class="custom-field">';
    		echo get_post_meta($post->ID, 'address', true);
    		echo '</p>';
    		echo '</article>';

    Regards,
    Yigit

    • This reply was modified 2 years, 3 months ago by Yigit.
    #1360846

    Hi Yigit
    it does not work.
    No output.

    Debugging gives nothing relevant:
    Warning: session_start(): Cannot start session when headers already sent in /wp-content/themes/enfold/config-templatebuilder/avia-shortcodes/masonry_entries/masonry_entries.php on line 102

    Eva

    OKAY: WORKS
    You had a typo (address instead of adress) and i didnt notice

    THANKS

    • This reply was modified 2 years, 3 months ago by evas49.
    #1360857

    Problem:
    In some cases the content of the CF is hidden behind the footer section.
    It happens when the nextgengallery (which is above the CF) contains more then about 8 images

    How do i fix this?

    Eva

    #1361037

    Hi,

    Glad to know that the modifications above are working properly. Regarding the footer issue, Please provide a link to the page containing the nextgen gallery so that we can check it properly.

    Best regards,
    Ismael

    #1362349

    Can we please agree on this??
    – I know that you want a link and i will provide one if i have one
    – You please understand that if i dont give one i dont have one.
    Can we?

    That would save a lot of time

    #1362410

    Hi Eva,

    In that case, please provide a link when one is available. We have to see the issue to be able to provide a solution.

    I tried to reproduce the issue by applying your customization and installing the 3rd party plugin, adding more than 8 images into the gallery but it works fine on my end.

    Regards,
    Yigit

Viewing 10 posts - 1 through 10 (of 10 total)
  • The topic ‘Custom field on blogpost’ is closed to new replies.