=== AffiliateBoxes.com Integration ===
Contributors: affiliateboxes
Donate link: https://affiliateboxes.com/
Tags: affiliateboxes, affiliate, gutenberg, box, shortcode
Requires at least: 5.8
Tested up to: 6.9
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPLv3
License URI: https://www.gnu.org/licenses/gpl-3.0.html

Display AffiliateBoxes.com products on your site using a block or shortcode. Products are served locally and sync automatically.

== Description ==

AffiliateBoxes.com Integration lets you insert rich affiliate product "boxes" created in your AffiliateBoxes.com account into WordPress posts, pages, and custom post types. Changes to the products are automatically synced to your WordPress site.



Features:
- Auto-sync: products synchronize automatically after changes on AffiliateBoxes.com.
- Gutenberg block: pick a product from your synced list with instant preview.
- Shortcode: `[affprod slug="your-product-slug"]` for use anywhere.
- Manual refresh: force a sync from the plugin settings screen.

You'll need an AffiliateBoxes.com account (free plan available) to connect your site.

== Installation ==

1. Upload the plugin files to the `/wp-content/plugins/` directory or install via Plugins → Add New.
2. Activate the plugin through the 'Plugins' screen in WordPress.
3. Go to Affiliate Products in your WP Admin menu and click Connect to link your site with AffiliateBoxes.com.
4. Use the "Affiliate Product" block in the editor, or add the shortcode where needed.

== Frequently Asked Questions ==

= Do I need an AffiliateBoxes.com account? =
Yes. Create products on AffiliateBoxes.com, then connect your WordPress site from the plugin settings.

= How do I insert a product with a shortcode? =
Use: `[affprod slug="your-product-slug"]`
Shortcodes are shown underneath the product when editing on AffiliateBoxes.com and listed on WP Admin under the Affiliate Products menu once the site is connected.


= Can I refresh products manually if things are out of sync? =
Yes. Use the "Force Synchronize" button on the settings screen to refresh immediately.
There is also a refresh button on the Gutenberg block that will refresh that specific product.
However, normally you would never need to do this, changes are sent to your WordPress site immediately when you save changes on AffiliateBoxes.com.


== Screenshots ==
1. Settings screen with synchronization controls and available products list.
2. Inserting a product via Shortcode
3. Gutenberg editor block

== Changelog ==

= 1.0.0 =
* Initial release: Connect, Synchronize, Gutenberg block, shortcode.

== Upgrade Notice ==

= 1.0.0 =
Initial release.

