Hastika Promo Bar

Description

Hastika Promo Bar is a powerful yet lightweight announcement bar plugin designed for WordPress. Create beautiful, highly customizable announcement bars at the top of your website with rich targeting options, scheduling, animations, countdown timers, and built-in analytics.

Key Features

  • Unlimited Announcements – Create as many announcements as you need
  • Auto-Rotation – Cycle through multiple announcements with smooth animations
  • 20+ Animation Effects – Fade, slide, zoom, flip, bounce, and more
  • Countdown Timers – Create urgency with live countdown timers
  • Scheduling – Set start and end dates for automatic activation/deactivation
  • Advanced Targeting – Control visibility by user role, login state, device type, and specific pages
  • WooCommerce Integration – Target customers, non-customers, or users who purchased specific products/categories
  • Clickable Bars – Make entire announcements clickable or add CTA buttons
  • Built-in Analytics – Track views, clicks, and CTR without external services
  • RTL Support – Full support for right-to-left languages
  • Lightweight & Fast – Pure JavaScript, no jQuery dependency, minimal assets
  • Fully Accessible – Keyboard navigation, ARIA labels, screen reader friendly
  • Responsive Design – Perfect display on mobile, tablet, and desktop
  • Import/Export – Backup and transfer settings via JSON

Perfect For

  • Product launches and special offers
  • Event announcements
  • Flash sales with countdown timers
  • Important site-wide notifications
  • Holiday promotions
  • Cookie notices
  • Newsletter signups

Bar Position Options

  • Standard – Scrolls naturally with the page
  • Fixed – Stays at the top while scrolling

Display Control

  • Set display delay (immediate or custom milliseconds)
  • Choose default open/collapsed state
  • User toggle with customizable persistence (session, 24h, 7d, 30d)
  • Device visibility (all, desktop only, mobile only, tablet only)
  • Show to specific user roles
  • Show to logged-in users, guests, or all visitors
  • Exclude/include specific pages by ID

Per-Announcement Options

  • Enable/disable status
  • Custom text with basic HTML support
  • Per-announcement colors (overrides global settings)
  • Device visibility override
  • User type targeting
  • Start/end date scheduling
  • CTA button with custom colors and URL
  • Make entire bar clickable
  • Optional icon (Dashicon or custom SVG)
  • Countdown timer with auto-hide option
  • WooCommerce customer targeting

Appearance Customization

  • Adjustable bar height (30-300px)
  • Content alignment (left, center, right)
  • Content order (text then CTA, or CTA then text)
  • Global and per-announcement colors
  • Font size control for text and CTA
  • Icon support (Dashicons or custom SVG)
  • Icon position (before or after text)

Built-in Analytics

Track performance without external services:

  • Total views per announcement
  • Total clicks per announcement
  • Click-through rate (CTR) percentage
  • Reset analytics per announcement
  • No tracking scripts loaded
  • Completely internal

Technical Highlights

  • WordPress Coding Standards compliant
  • Translation ready with .pot file included
  • Secure: nonce verification, sanitization, escaping
  • No PHP warnings or notices
  • OOP architecture
  • Lightweight: <100KB total assets
  • No external dependencies
  • SEO-friendly implementation

When Disabled

When the plugin is disabled, zero frontend assets are loaded:

  • No HTML output
  • No CSS loaded
  • No JavaScript loaded
  • No database queries

    Privacy Policy

    Hastika Promo Bar does not:

  • Collect any personal data

  • Use cookies
  • Send data to external servers
  • Load external tracking scripts

The plugin stores anonymous analytics data (view and click counts) locally in your WordPress database.

Screenshots

Installation

  1. Upload the hastika-promo-bar folder to the /wp-content/plugins/ directory, or install directly through the WordPress plugins screen.
  2. Activate the plugin through the ‘Plugins’ menu in WordPress.
  3. Navigate to Hastika Promo Bar in the WordPress admin menu.
  4. Enable the plugin, configure your settings, and create your first announcement.
  5. Save your changes and visit your site to see the announcement bar in action.

FAQ

Does this plugin slow down my website?

No. Hastika Promo Bar is designed with performance in mind. It loads minimal assets (<100KB total) and uses pure JavaScript without jQuery. When disabled, zero assets are loaded.

Can I have multiple announcements?

Yes! You can create unlimited announcements and choose to rotate through them automatically or display only the first one.

Can I schedule announcements?

Yes. Each announcement supports start and end date/time scheduling. Announcements will automatically activate and deactivate based on your schedule.

Does this work with WooCommerce?

Yes. Hastika Promo Bar includes WooCommerce integration that allows you to target customers, non-customers, or users who purchased specific products or categories.

Is it accessible?

Yes. The plugin is fully keyboard accessible, includes proper ARIA labels, supports screen readers, and has visible focus states on all interactive elements.

Does it support RTL languages?

Yes. The plugin fully supports right-to-left (RTL) languages with both auto-detection and manual force RTL/LTR options.

Can I make the entire bar clickable?

Yes. You can enable the “clickable announcement” option to make the entire bar a link, while still supporting separate CTA buttons.

How do countdown timers work?

Countdown timers display the remaining time (days, hours, minutes, seconds) until a specified end date/time. You can optionally hide the entire announcement when the countdown expires.

Can I target specific pages?

Yes. You can exclude specific page IDs or include only specific page IDs using comma-separated lists.

Is this GDPR compliant?

Yes. The plugin does not collect any personal data. Analytics are anonymous aggregates (views/clicks) stored locally in your database. No external services or tracking scripts are used.

Can I import/export settings?

Yes. The plugin includes JSON import/export functionality for easy backup and transfer of settings between sites.

Does it work with caching plugins?

Yes. The plugin is designed to work with caching plugins. Device visibility and user preferences are handled client-side via JavaScript.

Reviews

There are no reviews for this plugin.

Contributors & Developers

“Hastika Promo Bar” is open source software. The following people have contributed to this plugin.

Contributors

Translate “Hastika Promo Bar” into your language.

Interested in development?

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

Changelog

1.0.1

  • Fixed readme.txt stable tag to match plugin version
  • Updated tested up to WordPress 6.7
  • Fixed Author URI

1.0.0

  • Initial release
  • Unlimited announcements with rotation
  • 20+ animation effects
  • Countdown timers
  • Advanced targeting (roles, devices, pages, login state)
  • WooCommerce integration
  • Built-in analytics
  • RTL support
  • Import/export
  • Fully accessible
  • Translation ready