| 开发者 | brianhogg |
|---|---|
| 更新时间 | 2026年11月27日 03:19 |
| 捐献地址: | 去捐款 |
| PHP版本: | 7.4 及以上 |
| WordPress版本: | 7.2 |
| 版权: | GPL2 or later |
| 版权网址: | 版权信息 |
If you need extra design and functionality, Get The Events Calendar Shortcode & Block Pro! The Pro version adds more designs (compact, calendar, columns/grid, grouped, table and map), a slider, additional filtering options, and full control over how your events display. You get the same full integration with The Events Calendar, plus premium support, show multiple shortcodes on one page, a filter bar so users can find what events they want to see, and it works with any WordPress theme. Check out the Pro version todayTrusted by 10,000+ WordPress sites and a 4.7 star rating on WordPress.org, The Events Calendar Shortcode & Block is the solution you've been after :)
[ecs-list-events] shortcode to the page or post you want to list events on. Full list of options available in the documentation.Here's the full list of shortcode and block options you can use to customize how your events display:
[ecs-list-events][ecs-list-events cat='festival'] or specify multiple categories [ecs-list-events cat='festival, workshops'][ecs-list-events limit='3'][ecs-list-events order='DESC'][ecs-list-events eventdetails='false'][ecs-list-events venue='true'][ecs-list-events excerpt='true'] //displays excerpt with length 100
excerpt='300' //displays excerpt with length 300[ecs-list-events thumb='true'] //displays post thumbnail in default thumbnail dimension from media settings.[ecs-list-events thumb='true' thumbsize='large'][ecs-list-events thumb='true' thumbwidth='150' thumbheight='150'][ecs-list-events cat='festival' limit='3' order='DESC' viewall='false']title, thumbnail, excerpt, date, venue. [ecs-list-events cat='festival' limit='3' order='DESC' viewall='false' contentorder='title, thumbnail, excerpt, date, venue']'current' for displaying current month only or 'next' for next month. [ecs-list-events cat='festival' month='2024-06'][ecs-list-events cat='festival' past='yes'][ecs-list-events cat='festival' key='start date'][ecs-list-events orderby="enddate"][ecs-list-events days="1"] for one day or [ecs-list-events days="7"] for one week[ecs-list-events date='2024-04-16'][ecs-list-events year='2024'][ecs-list-events fromdate='2024-05-31' todate='2024-06-15'][ecs-list-events timeonly='true']Yes! There is now a block to list your events anywhere in a page or post, just click "+" in the top-left and search for The Events Calendar Block (under Common).
You can put the shortcode in a text widget.
Yes! This plugin includes an Elementor Widget.
Yes! This plugin includes a WPBakery Page Builder element. Add The Events Calendar Shortcode & Block element (under "Content") to show your events and choose your display options.
Yes! This plugin includes a module for both Divi 4 and Divi 5. In the Divi Builder, add The Events Calendar Shortcode & Block module to show your events with a live preview.
Yes. On WordPress 6.9 or later the plugin registers two read-only abilities with the WordPress Abilities API: the-events-calendar-shortcode/get-options lists every option with its choices and defaults, and the-events-calendar-shortcode/build-shortcode turns chosen options into an [ecs-list-events] shortcode and can preview its output. They are available through the REST API and the MCP Adapter plugin to users who can edit published posts.
No. Events Shortcodes For The Events Calendar (previously named "The Events Calendar Shortcode and Templates") is a separate plugin made by Cool Plugins, and it uses the [events-calendar-templates] shortcode. The Events Calendar Shortcode & Block is made by Event Calendar Newsletter and uses the [ecs-list-events] shortcode. The two plugins have different options, so the options on this page only work with [ecs-list-events].
By default the plugin does not include styling. Events are listed in ul li tags with appropriate classes for styling with a bit of CSS.
Put this in the template where you want the events list to display:
<?php echo do_shortcode("[ecs-list-events]"); ?>
The pro version of the plugin has the option to put design="calendar" in the shortcode (or pick Calendar as the design with the block) to show a calendar view of the events you want.