PHPackages                             offline/oc-opening-hours-plugin - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. offline/oc-opening-hours-plugin

ActiveOctober-plugin[Utility &amp; Helpers](/categories/utility)

offline/oc-opening-hours-plugin
===============================

Manage and display opening hours on your website

v1.0.19(1y ago)54997MITPHP

Since Jul 12Pushed 1y ago1 watchersCompare

[ Source](https://github.com/OFFLINE-GmbH/oc-opening-hours-plugin)[ Packagist](https://packagist.org/packages/offline/oc-opening-hours-plugin)[ RSS](/packages/offline-oc-opening-hours-plugin/feed)WikiDiscussions master Synced 2w ago

READMEChangelog (1)Dependencies (2)Versions (16)Used By (0)

oc-opening-hours-plugin
=======================

[](#oc-opening-hours-plugin)

> Manage and display opening hours on your website.

Features
--------

[](#features)

This plugins allows you to store opening hours for multiple locations and display them on your website.

It makes use of the great [`spatie/opening-hours`](https://github.com/spatie/opening-hours) library. You have direct access to all of the library's features.

- Store opening hours for multiple locations
- Set opening hours for each day of the week
- Add exceptions for specific dates
- Display the opening hours on your website
- Schema.org compatible [example markup](components/openinghours/) provided

`OpeningHours` component
------------------------

[](#openinghours-component)

This plugin provides only a single `OpeningHours` component. It can be used to display all opening hours for all locations.

```
[openingHours]
==
{# List all locations #}
{% for location in openingHours.locations %}
	{{ dump(location.openingHours.forWeek()) }}
{% endfor %}

{# If you have only a single location you can access it directly #}
{{ dump(openingHours.location.openingHours.forWeek()) }}

{# You can also access a specific location by its slug #}
{{ dump(openingHours.locationsBySlug['your-location'].openingHours.forWeek()) }}
```

Access the `openingHours` property on any location to have access to the full `spatie/opening-hours`featureset as [documented in their README](https://github.com/spatie/opening-hours#openinghoursforweek-spatieopeninghoursopeninghoursforday).

```
{{ dump(location.openingHours.forWeek()) }}
{{ dump(location.openingHours.forWeekCombined()) }}
{{ location.openingHours.asStructuredData() | json_encode }}
{{ location.openingHours.forDay('monday') }}
{{ location.openingHours.isOpenOn('monday') ? 'open' : 'closed' }}
{{ location.openingHours.isClosedOn('monday') ? 'closed' : 'open' }}
{{ location.openingHours.forDate(date('2020-01-01')) }}
{{ location.openingHours.isOpenAt(date('2020-10-01')) ? 'open' : 'closed' }}
{{ location.openingHours.isOpen() ? "We're open!" : "Sorry, we're closed!" }}
{{ location.openingHours.isClosed() ? "Sorry, we're closed!" : "We're open!" }}
{{ "Open until " ~ location.openingHours.nextClose(date('now')).format('Y-m-d H:i') }}
{{ "We'll open again on " ~ location.openingHours.nextOpen(date('now')).format('Y-m-d H:i') }}
```

Checkout the [component's partials](components/openinghours/) for a demo implementation.

Contributing
------------

[](#contributing)

### Bugs and feature requests

[](#bugs-and-feature-requests)

If you found a bug or want to request a feature please file a GitHub issue.

### Pull requests

[](#pull-requests)

PRs are always welcome! Open them against the `master` branch. If you plan a time consuming contribution please open an issue first and describe what changes you have in mind.

###  Health Score

39

—

LowBetter than 85% of packages

Maintenance42

Moderate activity, may be stable

Popularity20

Limited adoption so far

Community16

Small or concentrated contributor base

Maturity67

Established project with proven stability

 Bus Factor1

Top contributor holds 89.2% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~149 days

Recently: every ~303 days

Total

15

Last Release

461d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/8600029?v=4)[Tobias Kündig](/maintainers/tobias-kuendig)[@tobias-kuendig](https://github.com/tobias-kuendig)

---

Top Contributors

[![tobias-kuendig](https://avatars.githubusercontent.com/u/8600029?v=4)](https://github.com/tobias-kuendig "tobias-kuendig (33 commits)")[![damsfx](https://avatars.githubusercontent.com/u/282242?v=4)](https://github.com/damsfx "damsfx (1 commits)")[![Eoler](https://avatars.githubusercontent.com/u/680032?v=4)](https://github.com/Eoler "Eoler (1 commits)")[![gagegogan](https://avatars.githubusercontent.com/u/10763068?v=4)](https://github.com/gagegogan "gagegogan (1 commits)")[![patrick-durrer](https://avatars.githubusercontent.com/u/15232963?v=4)](https://github.com/patrick-durrer "patrick-durrer (1 commits)")

---

Tags

octobercmsoctobercms-pluginopening-hourscmsoctoberopening-hours

### Embed Badge

![Health badge](/badges/offline-oc-opening-hours-plugin/health.svg)

```
[![Health](https://phpackages.com/badges/offline-oc-opening-hours-plugin/health.svg)](https://phpackages.com/packages/offline-oc-opening-hours-plugin)
```

###  Alternatives

[helsingborg-stad/municipio

A bootstrap theme for creating municipality sites.

4028.3k10](/packages/helsingborg-stad-municipio)[october/rain

October Rain Library

1581.7M73](/packages/october-rain)[rainlab/blog-plugin

Blog plugin for October CMS

17158.6k](/packages/rainlab-blog-plugin)[responsiv/currency-plugin

Currency plugin for October CMS

181.3k1](/packages/responsiv-currency-plugin)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
