Filtering Popular Posts on Drupal: How to Filter by Time Frame with Views

| Drupal Development | 27 seen

In a previous tutorial, I showed how to use Views to filter popular posts on a Drupal site. Today, I will demonstrate how to filter popular posts within a specific time frame, such as a week or a month.

Note that this tutorial will only apply filters to the most viewed nodes based on their publishing date, not to all nodes within a certain time frame.

If you haven't already set up a popular blog post View, please refer to the link above and follow the steps to create your View.

To begin, open your popular blog post View and add a new filter under the "Filter" section. Select "Content: Post date" and choose "Operator: is between" in the filter settings.

In the "Min" field, enter the time frame you want Drupal to filter, for example, if you want to filter posts from the last 10 days, enter "-10 days" as the offset. In the "Max" field, enter the current time to ensure that future posts are not included in the filter.

If you have any questions or issues with this process, please leave a comment below and I will be happy to assist you.

 

Latest articles

Titanic Chaussee Hotel in Berlin

At the start of April 2026, we spent about six nights at Titanic Hotel Berlin (Chausseestraße 30). The trip was primarily work-related—my fiancée attended a conference in the translation industry—but it turned into a relaxed family stay, as I tagged along with our child during the Easter school break.The hotel sits in a convenient part of Berlin…

Germany |
Embedded thumbnail for Spring in Georgia: Morel Hunting, Gori Food Stop & Stunning Gorijvari Views

Spring in Georgia: Morel Hunting, Gori Food Stop & Stunning Gorijvari Views

Shot at the end of April 2026, on a calm and lovely Sunday morning, this video started with a simple plan: go out and hunt for morels -  murķeļi. Spring, fresh air, perfect timing… everything looked right.But plans shifted quickly.After the first attempts turned up nothing, we didn’t push too hard — instead, we adapted. Rather than chasing…

Living in Georgia |