Changeset 3694223
- Timestamp:
- 09/13/2026 09:50:24 PM (6 weeks ago)
- Location:
- ucd-ads/trunk
- Files:
-
- 3 edited
-
includes/class-ucd-shortcode.php (modified) (3 diffs)
-
readme.txt (modified) (3 diffs)
-
ucd-ads.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
ucd-ads/trunk/includes/class-ucd-shortcode.php
r3684915 r3694223 13 13 class UCD_Ad_Network_Shortcode 14 14 { 15 private const HANDLE_FIXED = 'ucd- ads';16 private const HANDLE_AUTOSCALE = 'ucd- ads-autoscale';15 private const HANDLE_FIXED = 'ucd-embed'; 16 private const HANDLE_AUTOSCALE = 'ucd-embed-autoscale'; 17 17 18 18 public static function init(): void … … 78 78 { 79 79 $ad_unit_id = esc_attr($ad_unit_id); 80 $attr = $autoscale ? 'data-ucd- ad-unit-autoscale' : 'data-ucd-ad-unit';80 $attr = $autoscale ? 'data-ucd-slot-autoscale' : 'data-ucd-slot'; 81 81 $style = sprintf('width:%dpx; height:%dpx;', $width, $height); 82 82 … … 106 106 * externally-hosted script/image. This is the plugin's core ad-serving function; see the 107 107 * "External services" section of readme.txt for the full disclosure. 108 * 109 * ucd-embed.js/ucd-embed-autoscale.js (not ucd-ads.js/ucd-ads-autoscale.js, and 110 * data-ucd-slot/-autoscale, not data-ucd-ad-unit/-autoscale) — some ad-blocker filter lists 111 * generically flag anything with "ads" in the script URL or attribute name, independent of 112 * this being an actual ad script. The old files/attribute stay live indefinitely for any site 113 * that hand-copied a snippet before this changed; this plugin itself always uses the current 114 * naming now. 108 115 */ 109 116 private static function maybe_script_tag(bool $autoscale): string 110 117 { 111 118 $handle = $autoscale ? self::HANDLE_AUTOSCALE : self::HANDLE_FIXED; 112 $file = $autoscale ? 'ucd- ads-autoscale.js' : 'ucd-ads.js';119 $file = $autoscale ? 'ucd-embed-autoscale.js' : 'ucd-embed.js'; 113 120 114 121 wp_enqueue_script($handle, UCD_AD_NETWORK_API_BASE . '/' . $file, [], UCD_AD_NETWORK_VERSION, true); -
ucd-ads/trunk/readme.txt
r3684915 r3694223 5 5 Tested up to: 7.1 6 6 Requires PHP: 7.4 7 Stable tag: 1. 1.47 Stable tag: 1.2.0 8 8 License: GPLv2 or later 9 9 License URI: https://www.gnu.org/licenses/gpl-2.0.html … … 86 86 * **On every page view that includes a `[ucd_ad]` shortcode, widget, or Elementor block**: the 87 87 visitor's own browser loads a small script directly from ads.urbancraftdepartment.com 88 (`/ucd- ads.js` or `/ucd-ads-autoscale.js`) and requests an ad to display. As with any such88 (`/ucd-embed.js` or `/ucd-embed-autoscale.js`) and requests an ad to display. As with any such 89 89 request, the visitor's IP address, User-Agent, and the referring page URL are visible to 90 90 ads.urbancraftdepartment.com as part of that request — the same as loading an image or script … … 105 105 106 106 == Changelog == 107 108 = 1.2.0 = 109 * Changed: the embed script and container attribute now load from `ucd-embed.js`/ 110 `data-ucd-slot` (previously `ucd-ads.js`/`data-ucd-ad-unit`) — some ad-blocker filter lists 111 generically flag anything with "ads" in a script URL or attribute name, blocking the ad for 112 visitors using them regardless of it being a real ad request. No action needed on your end; 113 existing shortcodes/widgets/blocks keep working exactly as before. 114 * Added: an advertiser can now attach optional caption text above/below an image creative — 115 shown automatically if a campaign uses it, no plugin configuration required. 107 116 108 117 = 1.1.4 = -
ucd-ads/trunk/ucd-ads.php
r3684915 r3694223 4 4 * Plugin URI: https://ads.urbancraftdepartment.com 5 5 * Description: Earn money from your site by showing UCD Ads Network ads. Connect your account, pick or create an ad unit, and place it with a shortcode, widget, or Elementor block — no minimum, no contract. 6 * Version: 1. 1.46 * Version: 1.2.0 7 7 * Requires at least: 5.8 8 8 * Requires PHP: 7.4 … … 19 19 } 20 20 21 define('UCD_AD_NETWORK_VERSION', '1. 1.4');21 define('UCD_AD_NETWORK_VERSION', '1.2.0'); 22 22 define('UCD_AD_NETWORK_DIR', plugin_dir_path(__FILE__)); 23 23 define('UCD_AD_NETWORK_URL', plugin_dir_url(__FILE__));
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)