Zum Inhalt springen
WordPress.org

Deutsch

  • Themes
  • Plugins
  • News
  • Support
  • Über
    • Learn WordPress
    • Documentation (en)
    • Foren
    • Developers (en)
    • WordPress.tv
  • Meetups
  • Mitmachen
  • FAQ
  • Hol dir WordPress
Hol dir WordPress
WordPress.org

Plugin Directory

Current Post Shortcode

  • Plugin einreichen
  • Meine Favoriten
  • Anmelden
  • Plugin einreichen
  • Meine Favoriten
  • Anmelden

Current Post Shortcode

Von Md Forid Uddin
Herunterladen
  • Details
  • Rezensionen
  • Installation
  • Entwicklung
Support

Beschreibung

The „Current Post Shortcode“ plugin allows you to display post titles and custom field values using simple shortcodes. You can display the current post’s title or meta information, or specify a post ID to retrieve data from a specific post.

Display Current Post Title and Meta Information:

  • Post Title: [current_post] → Outputs the current post title, e.g., „Hello World“
  • Post Meta (Custom Field): [current_post meta="custom_field"] → Outputs the value of the custom field

Display Data from a Specific Post ID:

  • Post Title: [current_post id="123"] → Outputs the title of the post with ID „123“
  • Post Meta (Custom Field): [current_post id="123" meta="custom_field"] → Outputs the value of the custom field in the post with ID „123“

Display Fallback Meta Value:

[current_post meta="custom_field" default="Default Value"]  → Displays "Default Value" if the custom field is empty

Display Default Value for Zero Meta Value:

[current_post meta="custom_field" default="Default Value" skip="true"]  → Displays "Default Value" if the custom field value is zero

Installation

From your WordPress dashboard:

  • Go to Plugins > Add New.
  • Search for ‚Current Post Shortcode‘.
  • Click „Install Now“, then „Activate Plugin“.

Or **install it manually**:

  • Download the plugin ZIP file from WordPress Directory.
  • Log in to your WordPress Dashboard, navigate to Plugins > Add New, and click the „Upload Plugin“ button.
  • Choose the plugin ZIP file and click „Install Now“.
  • After installation, click „Activate Plugin“.

FAQ

How do I use the shortcodes?

  • Use [current_post] to display the title of the current post.
  • Use [current_post meta="custom_field"] to display a custom field value.
  • To display data from a specific post, use the id attribute.

Can I use this shortcode in widgets or other areas of the site?

Yes, you can use these shortcodes anywhere shortcodes are supported in WordPress, such as posts, pages, widgets, Gutenberg blocks, and page builders like Elementor, Divi, WPBakery, etc.

How do I handle empty or zero meta values?

You can use the skip attribute to skip empty or zero values and optionally display a default value.

Is there a fallback for meta values?

Yes, you can use the default attribute to provide a fallback value for empty meta values.

Rezensionen

Für dieses Plugin gibt es keine Rezensionen.

Mitwirkende und Entwickler

„Current Post Shortcode“ ist Open-Source-Software. Folgende Menschen haben an diesem Plugin mitgewirkt:

Mitwirkende
  • Md Forid Uddin

Übersetze „Current Post Shortcode“ in deine Sprache.

Interessiert an der Entwicklung?

Durchstöbere den Code, sieh dir das SVN-Repository an oder abonniere das Entwicklungsprotokoll per RSS.

Änderungsprotokoll

3.1.0 – 14/01/2026

  • Added Shortcode functionality for displaying current post information.
  • Added support for displaying meta values with fallback options.

3.0.0 – 13/01/2026

  • Improved shortcode functionality to support additional attributes.
  • Enhanced compatibility with the latest WordPress versions.
  • Added fallback meta value for better user experience.

1.0.0 – 11/03/2025

  • Initial release of the plugin.

Meta

  • Version 3.1.0
  • Zuletzt aktualisiert vor 5 Monaten
  • Aktive Installationen 40+
  • WordPress-Version 6.7 oder höher
  • Getestet bis 6.9.4
  • PHP-Version 7.4 oder höher
  • Sprache
    English (US)
  • Schlagwörter
    custom fieldpost metapost titleshortcode
  • Erweiterte Ansicht

Bewertungen

Es wurden noch keine Rezensionen eingereicht.

Your review

Alle Rezensionen anzeigen

Mitwirkende

  • Md Forid Uddin

Support

Möchtest du etwas mitteilen? Brauchst du Unterstützung?

Support-Forum anzeigen

  • Über
  • News
  • Hosting (engl.)
  • Datenschutz
  • Showcase (engl.)
  • Themes
  • Plugins
  • Vorlagen
  • Learn
  • Support
  • Entwicklung (engl.)
  • WordPress.tv ↗
  • Mitwirken (engl.)
  • Veranstaltungen
  • Spenden (engl.) ↗
  • Five for the Future (engl.)
  • WordPress.com ↗
  • Matt (engl.) ↗
  • bbPress (engl.) ↗
  • BuddyPress (engl.) ↗
WordPress.org
WordPress.org

Deutsch

  • Unser X-Konto (früher Twitter) besuchen
  • Unser Bluesky-Konto besuchen
  • Unser Mastodon-Konto besuchen
  • Unser Threads-Konto besuchen
  • Unsere Facebook-Seite besuchen
  • Unser Instagram-Konto besuchen
  • Unser LinkedIn-Konto besuchen
  • Unser TikTok-Konto besuchen
  • Unseren YouTube-Kanal besuchen
  • Unser Tumblr-Konto besuchen
Code ist Poesie.
The WordPress® trademark is the intellectual property of the WordPress Foundation.