Skip to main content

Event Blocks

The `[event_blocks]` shortcode displays events as a vertical block layout — each event in its own card showing team logos, date, result or time, and optionally the event title, league, season, venue, and match day.

Updated today

Event Blocks

The [event_blocks] shortcode displays events as a vertical block layout — each event in its own card showing team logos, date, result or time, and optionally the event title, league, season, venue, and match day.

What It Displays

A paginated block-style table. Each row is one event with team logos side by side, the date, and the score or scheduled time. Optional metadata fields (league, season, venue, match day) appear below the score.

When to Use It

Use on any page, post, or widget. Supply id to pull events from a specific SportsPress Calendar. Without id, the shortcode uses get_the_ID().

Parameters

Parameter

Type

Default

Description

id

integer

null

Post ID of the SportsPress Calendar.

event

integer

null

Filter to a specific event post ID.

title

string/boolean

false

Override the displayed heading.

status

string

'default'

Event status filter: 'default', 'future', or 'publish'.

format

string

'default'

Event format filter.

date

string

'default'

Date preset filter.

date_from

string

'default'

Start of date range (YYYY-MM-DD).

date_to

string

'default'

End of date range (YYYY-MM-DD).

date_past

string

'default'

Days in the past to include.

date_future

string

'default'

Days in the future to include.

date_relative

string

'default'

Relative date mode.

day

string

'default'

Match day filter.

league

integer/string

null

League term ID or slug.

season

integer/string

null

Season term ID or slug.

venue

integer/string

null

Venue term ID or slug.

team

integer

null

Team post ID to filter events.

teams_past

integer

null

Filter to include past team associations.

date_before

string

null

Exclude events after this date.

player

integer

null

Player post ID to filter events.

number

integer

-1

Maximum number of events to show. -1 shows all.

columns

string/array

null

Comma-separated column slugs to override the Calendar's column config.

orderby

string

'default'

Field to order by (e.g. 'date', 'day').

order

string

'default'

Sort order: 'ASC' or 'DESC'.

show_team_logo

boolean

From settings

1 to display team logos. Default follows the Event Blocks > Display logos setting (yes).

link_teams

boolean

From settings

1 to link team logos to team pages.

link_events

boolean

From settings

1 to link dates and titles to event pages.

paginated

boolean

From settings

1 to paginate. Default follows the Event Blocks > Paginated setting.

rows

integer

From settings

Rows per page. Default follows the Event Blocks > Rows setting (default 5).

show_all_events_link

boolean

false

1 to show a "View all events" link (requires id).

show_title

boolean

From settings

1 to show the Calendar name as a heading.

show_league

boolean

From settings

1 to show the league below each event score.

show_season

boolean

From settings

1 to show the season below each event score.

show_matchday

boolean

From settings

1 to show the match day below each event score.

show_venue

boolean

From settings

1 to show the venue below each event score.

hide_if_empty

boolean

false

1 to suppress all output when there are no events.

Usage Examples

Minimal — all events from a specific calendar:

[event_blocks id="30"]

Future events with logos and venue, limited to 5:

[event_blocks id="30" status="future" show_team_logo="1" show_venue="1" number="5"]

Block layout grouped by match day, showing league and season metadata:

[event_blocks id="30" orderby="day" show_league="1" show_season="1"]

Did this answer your question?