=== GoldRateBD - Live Gold & Silver Price & Chart Widget ===
Contributors: goldratebd, sakilahmed
Donate link: https://goldratebd.com/
Tags: gold price, bajus gold price, gold rate bd, live gold price, gold rate
Requires at least: 5.0
Tested up to: 6.7
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Live Gold & Silver Price in Bangladesh. Displays official BAJUS 22K, 21K, 18K and traditional rates with interactive history chart.

== Description ==

**GoldRateBD** is the most reliable, modern, and lightweight WordPress plugin for displaying real-time **gold price** updates across Bangladesh.

Whether you run a news website, financial blog, jewelry store, or e-commerce platform, this plugin allows you to easily display official Bangladesh Jeweller's Association (BAJUS) rates for 22 Karat, 21 Karat, 18 Karat, and Traditional gold and silver.

### 🌟 Key Features

* **Official Live Rates**: Real-time gold and silver prices synchronized directly with official daily updates in Bangladesh.
* **All Karats Covered**: Displays 22 Karat (২২ ক্যারেট), 21 Karat (২১ ক্যারেট), 18 Karat (১৮ ক্যারেট), and Traditional (সনাতন) gold and silver rates.
* **Interactive Unit Switching**: Readers can toggle between Vori (ভরি), Gram (গ্রাম), and Ana (আনা) with a single click.
* **Interactive History Chart**: Displays sleek SVG trend charts for 7 Days, 30 Days, 1 Year, and 10 Years with zero external chart library bloat.
* **WordPress.org Compliant**: 100% clean, secure, local scripts and styles enqueued through standard WordPress APIs. No remote scripts executed on the client browser.
* **Mobile-First Responsive Design**: Works seamlessly on all smartphones, tablets, and desktop devices without breaking page layouts.
* **Smart Transient Caching**: Server-side 5-minute caching ensures lightning-fast page loading without slowing down your database.
* **Gutenberg, Elementor & Classic Support**: Insert with shortcodes or the built-in WordPress widget.

### 📌 Easy Shortcodes

Display anywhere in your posts, pages, or sidebar blocks:

* `[gold_price]` — Displays the full live gold and silver price table with unit toggles (ভরি, গ্রাম, আনা).
* `[gold_price_chart]` — Displays the interactive SVG price history chart (৭ দিন, ৩০ দিন, ১ বছর, ১০ বছর).
* `[gold_price_both]` — Displays both the price table and interactive history chart together.

== Installation ==

1. Upload the plugin zip directly via the WordPress Admin Plugins screen (**Plugins > Add New > Upload Plugin**).
2. Activate the plugin through the **Plugins** screen in WordPress.
3. Go to **Settings > GoldRateBD** to view shortcode guides and preview the live widgets.
4. Add the shortcode `[gold_price]` or `[gold_price_chart]` to any post, page, Elementor widget, or sidebar.

== Frequently Asked Questions ==

= Does this plugin display official gold prices? =
Yes. The plugin syncs with official Bangladesh Jeweller's Association (BAJUS) rates published daily in Bangladesh.

= What units are supported? =
Users can view prices per Vori (ভরি / 11.664g), per Gram (গ্রাম), and per Ana (আনা).

= Does the plugin slow down my website? =
No. The plugin uses server-side transient caching (cached for 5 minutes) and pure lightweight vanilla JavaScript. No heavy third-party JavaScript libraries (like Chart.js or jQuery plugins) are required.

= External Service / 3rd Party API Notice =
In compliance with WordPress.org guidelines, this plugin connects to an external service to fetch public market rates:
* **Service Provider**: GoldRateBD Live Rates Feed (`https://goldratebd.com/widget-data.json`) and fallback mirror (`https://raw.githubusercontent.com/nervyuzzal/goldbd/`).
* **Purpose**: To retrieve official 22K, 21K, 18K gold and silver market prices and historical price points for Bangladesh.
* **Data Transmitted**: No personal data, user tokens, cookies, or site credentials are sent. The request is a standard server-side HTTP GET request fetching public JSON market data.
* **Terms of Service**: https://goldratebd.com/terms/
* **Privacy Policy**: https://goldratebd.com/privacy-policy/

== Screenshots ==

1. Live Gold & Silver Price Table with Vori, Gram, and Ana unit selectors.
2. Interactive SVG Gold & Silver Price History Chart (7 Days, 30 Days, 1 Year, 10 Years).
3. WordPress Admin Settings Page with shortcodes and live preview.

== Changelog ==

= 1.0.0 =
* Initial official release.
* Added live gold & silver price table with Vori, Gram, and Ana unit conversion.
* Added interactive SVG history chart with multiple timeframe views.
* Added shortcodes: `[gold_price]`, `[gold_price_chart]`, `[gold_price_both]`.
* Added built-in WordPress sidebar widget and Gutenberg/Elementor shortcode support.
* Enhanced server-side transient caching and offline fallback rates.
* 100% WordPress.org plugin directory guideline compliance.

== Upgrade Notice ==

= 1.0.0 =
Initial official release.
