=== AdFusion === Contributors: brelandr Tags: ads, ad management, monetization, ad groups, shortcode Requires at least: 6.2 Tested up to: 6.9 Requires PHP: 7.4 Stable tag: 1.1.0 License: GPLv2 or later License URI: https://www.gnu.org/licenses/gpl-2.0.html Advanced ad management and monetization core foundation. Create, organize, and display ads with image, custom code, or text formats. == Description == AdFusion provides a solid foundation for managing advertisements on your WordPress site. Create ad units, organize them into groups for rotation, and display them anywhere using a simple shortcode. = Features = * **Custom Post Type** – Manage ads as a dedicated content type with full WordPress integration * **Ad Groups** – Organize ads into hierarchical groups (e.g., sidebar, header, footer) for easy rotation * **Multiple Ad Types** – Support for Image ads (featured image), Custom Code/HTML/AdSense, and Plain Text * **Scheduling** – Optional start and end dates for time-limited campaigns * **Shortcode** – Display ads by ID or group: `[adfusion id="123"]` or `[adfusion group="sidebar-ads"]` * **REST API** – Ads and groups exposed for future integrations (e.g., mobile apps) * **Extensible** – Hooks and filters for Premium extensions to build upon = Shortcode Usage = Display a specific ad by ID: `[adfusion id="123"]` Display a random ad from a group (rotates on each page load): `[adfusion group="sidebar-ads"]` = Ad Types = * **Image Ad** – Uses the post's featured image. Set a destination URL for click-through. * **Custom Code / HTML / AdSense** – Paste third-party ad code (e.g., Google AdSense) for direct embedding. * **Plain Text** – Simple text ads with optional link. == Installation == 1. Upload the plugin files to `/wp-content/plugins/adfusion-ad-manager-and-monetization/`, or install through WordPress plugins screen. 2. Activate the plugin through the 'Plugins' screen in WordPress. 3. Go to AdFusion in the admin menu to create ads and ad groups. 4. Use the shortcode `[adfusion id="X"]` or `[adfusion group="your-group-slug"]` in posts, pages, or widgets. == Frequently Asked Questions == = How do I create an ad group? = Go to AdFusion → Ads, then click "Ad Groups" in the submenu. Add new groups (e.g., "sidebar-ads", "header-banner") and assign ads to them when editing an ad. = Can I use Google AdSense? = Yes. Create an ad, select "Custom Code / HTML / AdSense" as the ad type, and paste your AdSense code in the Ad Code field. You need the `unfiltered_html` capability to save raw ad code. = Do ads have their own URLs? = No. Ads are set to `public: false`, so they do not have individual frontend pages. They are only displayed via the shortcode. == External Services == = Google AdSense = When AdSense fallback or Google Ads is enabled in Settings, the plugin loads the Google AdSense script from `https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js`. Your publisher ID (from the plugin settings) is passed as the `client` query parameter. No data is sent to AdFusion servers; the script communicates directly with Google's ad servers when ads are displayed. * [Google AdSense Terms of Service](https://www.google.com/adsense/new/localized-terms) * [Google Privacy Policy](https://policies.google.com/privacy) == Screenshots == 1. Ad list and Ad Groups in the admin 2. Ad Details & Configuration meta box 3. Shortcode output example == Changelog == = 1.1.0 = * Maintenance release. = 1.0.0 = * Initial release * Custom Post Type for ads * Ad Groups taxonomy * Image, Code, and Text ad types * Start/End date scheduling * [adfusion] shortcode with id and group attributes * REST API support for ads and groups == Upgrade Notice == = 1.1.0 = Maintenance release. = 1.0.0 = Initial release of AdFusion.