• jk1459

    (@jk1459)


    Hey All,

    I tried to do this myself and really messed things up so now i am asking for help.

    I am using this theme:https://www.fabthemes.com/hunter/

    I have a lot of “posts” featured on my homepage (nearly 50), and i want them to all show up in a random order, versus the order i created them. Is there any efficient way to do this given the above theme?

    I will be very grateful for any help

    Jonathan

Viewing 2 replies - 1 through 2 (of 2 total)
  • Johnathan

    (@jelyman)

    Maybe, but it’d be dirty and not very efficient from a code perspective.

    1. Count the number of posts available.
    2. Create a loop.
    3. Take a random number from 1 to the limit, and call forth that post.
    4. Repeat 3 until you reach the limit (quantity) or a pre-defined quantity.
    5. You’d be making X individual requests until you call forth all the posts you desire.

    I can’t say if there’s a way to do it natively.

    Thread Starter jk1459

    (@jk1459)

    Thanks Johnathan – would this solution switch up the order of the posts? Can you advise on what code i could use to do this and where i could put such code?

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Home page posts (randomizing) help’ is closed to new replies.