Linux 软件免费装
Banner图

Indesign Nepali Post Date

开发者 indesignmedia
更新时间 2026年4月22日 19:11
PHP版本: 8.2 及以上
WordPress版本: 6.9
版权: GPLv2 or later
版权网址: 版权信息

标签

nepali calendar nepali post date nepali date bikram sambat BS date

下载

1.0.0

详情介绍:

Indesign Nepali Post Date converts Gregorian (AD) dates into Bikram Sambat (BS) Nepali dates directly within WordPress — with full support for Nepali glyphs, localized month and weekday names, and flexible formatting. It is built for Nepali news portals, blogs, and any website that must display publish dates, modified dates, or today's date in the Nepali calendar format, as required by Nepal Press Council regulations. Key highlights:

安装:

  1. Upload the indesign-nepali-post-date folder to the /wp-content/plugins/ directory, or install it directly through the WordPress plugin screen.
  2. Activate the plugin through the Plugins screen in WordPress.
  3. Go to Settings → Indesign Nepali Post Date to configure the date format, localization style, and optional CSS class.
  4. Add a shortcode such as [indnpd_post_date] or [indnpd_today_date] anywhere in your content.

屏幕截图:

  • Front-end date display

常见问题:

What calendar system does this plugin use?

The plugin converts dates from the Gregorian calendar (AD) to the Bikram Sambat (BS) calendar — the official calendar of Nepal. For example, AD 2024 corresponds approximately to BS 2081.

What date range is supported?

The plugin supports BS 2000 to BS 2101, which corresponds to AD 1943-04-14 through AD 2044. Dates outside this range will be returned as-is without conversion.

How do I display the post date in Nepali inside my theme template?

Use the global PHP function anywhere inside The Loop: <?php echo id_nepali_post_date_get( get_the_date('Y-m-d H:i:s') ); ?> Or use the namespaced helper for more control: <?php echo indnpd_get_date( get_the_date('Y-m-d H:i:s'), 'd M Y, l', 'nepali' ); ?>

Can I use English digits instead of Nepali glyphs?

Yes. Go to Settings → Indesign Nepali Post Date and set Localization Style to Global English (0123). You can also override this per shortcode using the lang attribute: [indnpd_post_date lang="english"] Or per function call by passing "english" as the third argument to indnpd_get_date().

Can I customize the date format?

Yes. In the settings panel, enter a custom Date Pattern using the supported tokens: d (day), m (month number), M (month name), y (2-digit year), Y (4-digit year), l (weekday name). For example, d M Y, l outputs २५ असार २०८१, मंगलबार. You can also pass a custom format directly in a shortcode: [indnpd_post_date format="d M Y"]

How do I hook into the date output programmatically?

Use the indesign_nepali_post_date_output WordPress filter. It passes three arguments: the formatted HTML string, the BS date array, and the Unix timestamp. add_filter( 'indesign_nepali_post_date_output', function( $html, $bs, $unix ) { return '<span class="nepali-badge">' . $html . '</span>'; }, 10, 3 );

更新日志:

1.0.0