WordPress.org

Ready to get started?Download WordPress

Forums

How select the 'posts' from the current time and the 'post' preceding? (2 posts)

  1. webipsum
    Member
    Posted 2 years ago #

    Hi.

    I have posts that make up a program schedule (only start time of the program).

    Example:
    Post A: 02:00 H Program Number 1
    Post B: 02:30 H Program Number 2
    Post C: 03:00 H Program Number 3
    Post D: 03:55 H Program Number 4

    Assuming they are 02:05 H, are shown, the example above:
    Post B: 02:30 H Program Number 2
    Post C: 03:00 H Program Number 3
    Post D: 03:55 H Program Number 4

    As it was 02:05 H the program that is in the air, is not displayed:

    Post A: 02:00 H Program Number 1

    I need to display it and mark it as in the air.

    So basically, what I need is to select the posts of programs from the current time and the post immediately preceding.

    Please, any tips?

    Thank you.

  2. webipsum
    Member
    Posted 2 years ago #

    :-(
    I gave a solution with a loop to get the previous posts and another loop to get the next posts ...
    :-)

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.