[Support request] random pages shortcode function

Home Forums Support random pages shortcode function

  • This topic has 3 replies, 2 voices, and was last updated 1 month ago by David.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #1418751
    Juan Jose

    I want to show under each page, 6 random pages without showing the current page, how could I do this script?
    Could it be done with a shortcode function?

    #1418804
    David
    Staff
    Customer Support

    Hi there,

    try the WP Show Posts plugin.

    https://wordpress.org/plugins/wp-show-posts/

    You can create a new list, and from the More Settings you can check ‘Exclude Current’ and set the Order By to Random.

    #1418901
    Juan Jose

    Thanks, I have installed it, but when I try to exclude a page, like the home page, it doesn’t exclude it, how can I do it?

    flameshot_screenshot

    #1418929
    David
    Staff
    Customer Support

    There is also a field named Exclude IDs – you can add the ID of the home page in there.

    You can get its ID by Right Click inspecting the Home Page in the live site. You will see something like page-id-123 which you would enter just 123 into the field.

    Or you can see the same number by editing the Home Page and checking the URL.

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.