Show Post In lightbox

Priskribo

Show Post In lightbox lists posts from a category on any page, post or sidebar. Visitors click a title and the post opens in a lightbox, without leaving the page.

  • [ostlist] shortcode for posts and pages. Use it as many times as you like.
  • “Show Posts By Category” widget for sidebars.
  • Optional post date and featured image thumbnail.
  • Accessible lightbox: keyboard friendly, closes with Esc, returns focus to the link.
  • Only published, public, non-password-protected posts are ever shown.
  • Without JavaScript the links open the normal post page.

Shortcode

[ostlist catid="3" limit="5" orderby="title" order="ASC" showdate="Y" showthumbnail="thumbnail"]
  • catid – category ID, or several IDs separated by commas. Default: all categories.
  • limit – number of posts, 1 to 100. Default: 10.
  • orderby – date, title, author, rand, modified, ID or menu_order. Default: date.
  • order – ASC or DESC. Default: DESC.
  • catnotin – category IDs to exclude, separated by commas.
  • postnotin – post IDs to exclude, separated by commas.
  • showdate – Y to show the post date. Default: N.
  • showthumbnail – an image size (thumbnail, medium, large, full) or a width and height such as 50,50. Leave empty for no image.

Instalo

  1. In your WordPress admin go to Plugins > Add New, search for “Show Post In lightbox”, then install and activate it.
  2. Add the [ostlist] shortcode to a post or page, or add the “Show Posts By Category” widget under Appearance > Widgets.

OD

Can private or draft posts appear in the lightbox?

No. The lightbox only loads posts that anyone can already read on your site. Drafts, private, scheduled and password-protected posts are refused.

Do my existing shortcodes and widgets still work after updating to 2.0.0?

Yes. The shortcode name, its attributes and the widget settings are unchanged.

The lightbox looks different from version 1.0

Version 2.0.0 uses a new, lighter lightbox. If your theme styled the old .confirmon-box classes, update your CSS to target .spbc-lightbox.

Pritaksoj

Legi ĉiujn 2 pritaksojn

Kontribuantoj k. programistoj

“Show Post In lightbox” estas liberkoda programo. La sekvaj homoj kontribuis al la kromprogramo.

Kontribuantoj

Traduki “Show Post In lightbox” en vian lingvon.

Ĉu interesita en programado?

Browse the code, check out the SVN repository, or subscribe to the development log by RSS.

Ŝanĝprotokolo

2.0.0

  • Security: the lightbox could display any post, including drafts, private and password-protected posts. It now only shows public posts.
  • Security: all output is escaped and all shortcode and widget settings are validated.
  • Fixed fatal errors on PHP 8 (removed create_function and the PHP 4 widget constructor).
  • New accessible lightbox using the native dialog element; no jQuery needed.
  • Posts load through a read-only REST API route; old ?popup=Y links now redirect to the post.
  • Scripts and styles load only on pages that show a list.
  • Widget settings now remember the selected order, order by and thumbnail size.
  • Category lists include posts in child categories, as before.
  • Now requires WordPress 6.0 and PHP 7.4 or later. Tested up to WordPress 7.1.
  • License changed to GPLv2 or later.

1.0

  • Initial release.