Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Adam Capriola

    (@adamcapriola)

    get_post_meta( $post->ID, 'views', true ); would be used in a theme .php file.

    [view-count] could be used in a post/page or a theme file filter function.

    Thread Starter GuyOlinga

    (@guyolinga)

    Hello Adam,

    I was not able to see my stats on the front-end with the function get_post_meta( $post->ID, ‘views’, true ); added to wp-includes/theme.php

    However, [view-count] displays the correct value (but on a single post) of the views that I can also see in the field postmeta –> views.

    Please could you tell me more on how to use the fonction get_post_meta( $post->ID, ‘views’, true ); as the data in the postmeta file are accurate.

    I would really appreciate your support

    Thanks
    Guy

    Plugin Author Adam Capriola

    (@adamcapriola)

    You probably need global $post; stated in the function beforehand.

    Thread Starter GuyOlinga

    (@guyolinga)

    This is the answer from Gabfire support

    open single.php and page.php
    Paste this
    $views = get_post_meta( $post->ID, ‘views’, true );
    echo “lu $views fois”;

    right after the_content();

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘I don't understand this 4. step in the install procedure’ is closed to new replies.