How To Redirect Website Users And Viewers To A Random Post On WordPress

Sean Doyle

Sean Doyle is an engineer from Los Angeles, California. Sean's primary focuses include Internet Security, Web Spam, and Online Marketing.

13 Responses

  1. Awesome, works great, I was looking for this code for ages.

  2. Thanks, that was easy!

  3. Christopher says:

    Others wrote bad redirect codes which I ended up getting penalized for.
    I now figure because they didn’t include the 307 in their redirect code part only a 302.
    Thank you for sharing, wish I found this first.

  4. Good post. Always works like a charm.

    This is the right way to redirect users.

    You can also change the number of posts from 1:
    ‘numberposts’ => 10,

  5. Brian says:

    Thanks for including the 307 redirect code.

Leave a Reply

Your email address will not be published.