• Resolved deeveearr

    (@deeveearr)


    Hi,

    I’ve been sent over here by Smart Slider.

    Smart Slider allows you to build ‘dynamic slides’, which is just a way of pulling in the latest blog posts.

    The reason that they sent me over here is that I cannot work out which of the meta fields in WPP stores the ‘hits count’.

    With this hits count field enabled in Smart Slider, it would allow me to build a really nice looking ‘trending posts’ slider (hopefully) πŸ™‚

    Any help on this would be much appreciated.

Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Author Hector Cabrera

    (@hcabrera)

    Hi @deeveearr,

    WordPress Popular Posts doesn’t use meta fields to store views data. Actually the plugin saves said data in two custom database tables.

    There’s a pinned topic here that explains how to save views data on meta fields though: How To: Sorting a Custom Query by Views (and this is exactly what you need to sort your Smart Slides by views :P)

    Thread Starter deeveearr

    (@deeveearr)

    Hi @hcabrera

    Yes, I’ve been looking through a few of the pinned posts.

    No problem with part one – just throw the whole lot into code snippets.

    Where do I add the code for part two though – ‘create a new WP query’?

    Plugin Author Hector Cabrera

    (@hcabrera)

    No need, that’s what Smart Slider will do for you under the hood.

    Thread Starter deeveearr

    (@deeveearr)

    Ok then @hcabrera – just add part one it is!

    Thread Starter deeveearr

    (@deeveearr)

    Tried adding part one of the post above, and it refused to save in code snippets.

    So I went over to the theme editor and tried to save it in functions.php and it refused to save in there too.

    Plugin Author Hector Cabrera

    (@hcabrera)

    Most likely you have a security / firewall plugin preventing you from doing so, or you may have disabled file editing via wp-config.php. You can edit the functions.php file manually I guess (assuming you have access to the server of course, if not then ask someone who does) or you can temporarily disable said security / firewall plugin (or update your wp-config.php file to remove the restriction), do your thing, then enable it back when you’re done.

    P.S.: Not sure why you marked this thread as Unresolved though. How does not being able to update files on your server have anything to do with the topic we’re discussing here?

    Thread Starter deeveearr

    (@deeveearr)

    Oh right, I just thought that there might have been something wrong with the code.

    Yes, I’m using Wordfence, so I’ll disable it for five minutes.

    Thread Starter deeveearr

    (@deeveearr)

    Yep, all done, and accuracy set to 100 before I visit a few posts.

    Plugin Author Hector Cabrera

    (@hcabrera)

    Awesome! Well, enjoy your Popular Posts slideshow πŸ˜›

    Have a nice week!

    Thread Starter deeveearr

    (@deeveearr)

    Yes, working really well now after I remembered to add a few parameters to the shortcodes.

    I’ll get on with my slider following some dinner.

    Thanks again!

Viewing 10 replies - 1 through 10 (of 10 total)

The topic ‘‘Hits’ Field?’ is closed to new replies.