Changeset 3844099
- Timestamp:
- 12/04/2026 09:42:13 AM (2 hours ago)
- Location:
- varly
- Files:
-
- 16 edited
- 1 copied
-
assets/screenshot-1.png (modified) ( previous)
-
assets/screenshot-3.png (modified) ( previous)
-
tags/1.4.2 (copied) (copied from varly/trunk )
-
tags/1.4.2/includes/class-varly-admin.php (modified) (11 diffs)
-
tags/1.4.2/includes/class-varly-connect.php (modified) (4 diffs)
-
tags/1.4.2/includes/class-varly-order-list.php (modified) (1 diff)
-
tags/1.4.2/includes/class-varly-settings.php (modified) (3 diffs)
-
tags/1.4.2/includes/class-varly-woocommerce.php (modified) (1 diff)
-
tags/1.4.2/readme.txt (modified) (6 diffs)
-
tags/1.4.2/varly.php (modified) (2 diffs)
-
trunk/includes/class-varly-admin.php (modified) (11 diffs)
-
trunk/includes/class-varly-connect.php (modified) (4 diffs)
-
trunk/includes/class-varly-order-list.php (modified) (1 diff)
-
trunk/includes/class-varly-settings.php (modified) (3 diffs)
-
trunk/includes/class-varly-woocommerce.php (modified) (1 diff)
-
trunk/readme.txt (modified) (6 diffs)
-
trunk/varly.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
varly/tags/1.4.2/includes/class-varly-admin.php
r3842788 r3844099 68 68 69 69 /** 70 * "Settings" next to Deactivate on the Plugins screen. 70 * "Settings" next to Deactivate on the Plugins screen. The word is WordPress's own, without a text 71 * domain, so it is in the language of the admin right away. 71 72 * 72 73 * @param string[] $links Links. … … 74 75 */ 75 76 public static function action_links( $links ) { 76 array_unshift( $links, '<a href="' . esc_url( Varly_Connect::settings_url() ) . '">' . esc_html__( 'Settings', 'varly' ) . '</a>' ); 77 // phpcs:ignore WordPress.WP.I18n.MissingArgDomain -- On purpose: WordPress's own translation of "Settings". 78 array_unshift( $links, '<a href="' . esc_url( Varly_Connect::settings_url() ) . '">' . esc_html__( 'Settings' ) . '</a>' ); 77 79 return $links; 78 80 } … … 153 155 public static function no_visits_text() { 154 156 if ( Varly_Settings::consent_gated() && array() === Varly_Consent::tools() ) { 155 return __( 'No visits in the last 24 hours. Varly only measures visitors who accept cookies, and this plugin found no cookie banner on your site. Without a banner, nobody can accept, so nothing is measured. Add a cookie banner, for example Complianz or CookieYes. Using another banner? Open your site in a private window and accept cookies; the visit shows up here within a few minutes (click Check again).', 'varly' );156 } 157 return __( 'No visits in the last 24 hours. Open your site in a private window and accept cookies; the visit shows up here within a few minutes (click Check again).', 'varly' );157 return __( 'No visits in the last 24 hours. Varly only measures visitors who accept cookies, and this plugin found no cookie banner on your site. Without a banner, nobody can accept, so nothing is measured. Add a cookie banner, for example Complianz or CookieYes. Using another banner? Open your site in a private window and accept cookies; the visit shows up here within a few minutes (click Check status again).', 'varly' ); 158 } 159 return __( 'No visits in the last 24 hours. Open your site in a private window and accept cookies; the visit shows up here within a few minutes (click Check status again).', 'varly' ); 158 160 } 159 161 … … 178 180 ); 179 181 180 if ( '1' === $settings['snippet'] ) { 182 // Varly answered and does not know the site key (a typing mistake, or the site was deleted in 183 // Varly): the snippet tag is on the site, but there is no script behind it. 184 $unknown = is_array( $status ) && $status['reached'] && ! $status['known']; 185 186 if ( '1' === $settings['snippet'] && $unknown ) { 187 self::status_row( __( 'Snippet', 'varly' ), 'warning', __( 'Added to every page, but Varly does not know this site key, so the snippet does nothing yet.', 'varly' ) ); 188 } elseif ( '1' === $settings['snippet'] ) { 181 189 self::status_row( __( 'Snippet', 'varly' ), 'ok', ( '1' === Varly_Settings::value( 'skip_checkout' ) && Varly_WooCommerce::active() ? __( 'Added to the top of every page, except the checkout (you left it out below).', 'varly' ) : __( 'Added to the top of every page, including the cart and checkout.', 'varly' ) ) ); 182 190 } else { … … 186 194 if ( ! is_array( $status ) || ! $status['reached'] ) { 187 195 self::status_row( __( 'Data in Varly', 'varly' ), 'info', __( 'Could not reach Varly to check right now. This does not affect your site.', 'varly' ) ); 188 } elseif ( ! $status['known']) {189 self::status_row( __( 'Data in Varly', 'varly' ), 'error', __( 'Varly does not know this site key. Click Connect to Varly again .', 'varly' ) );196 } elseif ( $unknown ) { 197 self::status_row( __( 'Data in Varly', 'varly' ), 'error', __( 'Varly does not know this site key. Click Connect to Varly again, or check the site key under Enter keys yourself.', 'varly' ) ); 190 198 } elseif ( ! $status['tracking'] ) { 191 199 self::status_row( __( 'Data in Varly', 'varly' ), 'warning', __( 'Tracking is off in Varly, so nothing is measured yet. In Varly, open your site and click Turn tracking on under Install.', 'varly' ) ); … … 214 222 } elseif ( ! empty( $state['last_sent'] ) ) { 215 223 /* translators: 1: order number, 2: "5 minutes ago". */ 216 self::status_row( __( 'Orders', 'varly' ), 'ok', sprintf( __( 'Sent to Varly in the background. The last one, order %1$s, w ent %2$s.', 'varly' ), $state['last_order'], self::ago( (int) $state['last_sent'] ) ) );224 self::status_row( __( 'Orders', 'varly' ), 'ok', sprintf( __( 'Sent to Varly in the background. The last one, order %1$s, was sent %2$s.', 'varly' ), $state['last_order'], self::ago( (int) $state['last_sent'] ) ) ); 217 225 } else { 218 226 self::status_row( __( 'Orders', 'varly' ), 'ok', __( 'Ready. Every paid order is sent to Varly in the background; refunds and cancellations update it.', 'varly' ) ); … … 243 251 return; 244 252 } 253 // First what Varly says (kept for two minutes): it can change a setting shown below, such as 254 // longer recognition in Safari. 255 Varly_Connect::status(); 245 256 $settings = Varly_Settings::get(); 246 257 $connected = Varly_Settings::connected(); … … 283 294 </table> 284 295 <div class="varly-actions"> 285 <?php self::action_button( 'varly_refresh_status', __( 'Check again', 'varly' ) ); ?>296 <?php self::action_button( 'varly_refresh_status', __( 'Check status again', 'varly' ) ); ?> 286 297 <?php self::action_button( 'varly_connect', __( 'Connect to Varly again', 'varly' ) ); ?> 287 298 <?php if ( Varly_Order_List::enabled() ) : ?> … … 326 337 <th scope="row"><?php esc_html_e( 'Returning visitors in Safari', 'varly' ); ?></th> 327 338 <td> 328 <p><strong><?php echo esc_html( '1' === $settings['keep'] ? __( 'On: recognized for up to a year', 'varly' ) : __( 'Off: recognized for 7 days', 'varly' ) ); ?></strong></p> 329 <p class="description"><?php esc_html_e( 'Safari deletes cookies set by scripts after 7 days, so a visitor who comes back later can get the other version of a running test. You turn this on or off in Varly, under Settings → A/B testing. When it is on, your site keeps a copy of Varly’s visitor ID in a cookie it sets itself (_varly_keep, one year), only for visitors who accepted cookies, and removes it when they decline. Add _varly_keep to your cookie list before you turn it on.', 'varly' ); ?></p> 339 <?php // Information only: this is set in Varly (Settings → Tracking & privacy), so there is no box to tick here. ?> 340 <?php if ( '1' === $settings['keep'] ) : ?> 341 <p><?php esc_html_e( 'On. You turn this off in Varly, under Settings → Tracking & privacy.', 'varly' ); ?></p> 342 <p class="description"><?php esc_html_e( 'Safari forgets a visitor after 7 days, so someone who comes back later could see the other version of a running test. With this on, Varly recognizes them for up to a year. Your site sets one cookie for it, _varly_keep (kept for one year), only for visitors who accepted cookies. Make sure it is on your cookie list.', 'varly' ); ?></p> 343 <?php else : ?> 344 <p><?php esc_html_e( 'Off. You turn this on in Varly, under Settings → Tracking & privacy.', 'varly' ); ?></p> 345 <p class="description"><?php esc_html_e( 'Safari forgets a visitor after 7 days, so someone who comes back later can see the other version of a running test. With this on, Varly recognizes them for up to a year. Your site then sets one cookie, _varly_keep (kept for one year), only for visitors who accepted cookies. Add it to your cookie list before you turn this on.', 'varly' ); ?></p> 346 <?php endif; ?> 330 347 </td> 331 348 </tr> … … 348 365 <td> 349 366 <input id="varly_api_key" name="<?php echo esc_attr( $option ); ?>[api_key]" type="password" class="regular-text code" value="" autocomplete="new-password" spellcheck="false" placeholder="<?php echo esc_attr( '' !== $settings['api_key'] ? __( 'Saved. Leave empty to keep it.', 'varly' ) : 'sk_…' ); ?>" /> 350 <p class="description"><?php esc_html_e( 'Starts with sk_. In Varly under Install → Connect your orders, an owner clicks Create API key. With it, the plugin sends every paid order to Varly.', 'varly' ); ?></p>367 <p class="description"><?php esc_html_e( 'Starts with sk_. In Varly, go to Install → Connect your orders and click Create API key (only an owner of the Varly account can do this). With this key, the plugin sends every paid order to Varly.', 'varly' ); ?></p> 351 368 </td> 352 369 </tr> … … 355 372 </details> 356 373 357 <?php submit_button( __( 'Save changes', 'varly' ) ); ?> 374 <?php // WordPress's own "Save Changes", in the language of the admin. ?> 375 <?php submit_button(); ?> 358 376 </form> 359 377 -
varly/tags/1.4.2/includes/class-varly-connect.php
r3842788 r3844099 172 172 173 173 /** 174 * Only administrators of this site. 175 * 176 * @return void 177 */ 178 p rivatestatic function require_admin() {174 * Only administrators of this site. One message for every button on Settings → Varly. 175 * 176 * @return void 177 */ 178 public static function require_admin() { 179 179 if ( ! current_user_can( 'manage_options' ) ) { 180 180 wp_die( esc_html__( 'You need to be an administrator of this site to do this.', 'varly' ), 403 ); … … 448 448 ); 449 449 Varly_Compat::purge_page_cache(); 450 if ( $had_key && $copy ) { 451 self::notice( 'success', __( 'Disconnected. The Varly snippet is no longer on this site, and it sends no orders. This site looked like a copy, so the order API key keeps working for the site it was first connected on.', 'varly' ) ); 452 } elseif ( $had_key && ! $revoked ) { 453 self::notice( 'warning', __( 'Disconnected. The Varly snippet is no longer on your site, and orders are no longer sent. Varly could not be reached to stop the order API key: it keeps working in Varly until you create a new one under Install → Connect your orders.', 'varly' ) ); 454 } else { 455 self::notice( 'success', __( 'Disconnected. The Varly snippet is no longer on your site, and orders are no longer sent to Varly.', 'varly' ) ); 456 } 450 $notice = self::disconnect_notice( $had_key, $copy, $revoked ); 451 self::notice( $notice[0], $notice[1] ); 457 452 self::back(); 453 } 454 455 /** 456 * What Settings → Varly says after Disconnect. Orders are only mentioned when this site had an 457 * order API key: without one it never sent any. 458 * 459 * @param bool $had_key An order API key was saved. 460 * @param bool $copy This site looked like a copy (see Varly_Settings::is_copy()). 461 * @param bool $revoked Varly confirmed that the order API key stopped. 462 * @return array{0: string, 1: string} Type and message, as for notice(). 463 */ 464 public static function disconnect_notice( $had_key, $copy, $revoked ) { 465 if ( ! $had_key ) { 466 return array( 'success', __( 'Disconnected. The Varly snippet is no longer on your site.', 'varly' ) ); 467 } 468 if ( $copy ) { 469 return array( 'success', __( 'Disconnected. The Varly snippet is no longer on this site, and it sends no orders. This site looked like a copy, so the order API key keeps working for the site it was first connected on.', 'varly' ) ); 470 } 471 if ( ! $revoked ) { 472 return array( 'warning', __( 'Disconnected. The Varly snippet is no longer on your site, and orders are no longer sent. Varly could not be reached to stop the order API key: it keeps working in Varly until you create a new one under Install → Connect your orders.', 'varly' ) ); 473 } 474 return array( 'success', __( 'Disconnected. The Varly snippet is no longer on your site, and orders are no longer sent to Varly.', 'varly' ) ); 458 475 } 459 476 … … 485 502 486 503 /** 487 * "Check again": fetch the status from Varly now.504 * "Check status again": fetch the status from Varly now, and say that it happened. 488 505 * 489 506 * @return void … … 493 510 check_admin_referer( 'varly_refresh_status' ); 494 511 delete_transient( self::STATUS_TRANSIENT ); 512 $notice = self::refresh_notice( self::status() ); 513 self::notice( $notice[0], $notice[1] ); 495 514 self::back(); 515 } 516 517 /** 518 * What Settings → Varly says after Check status again. Without it the page reloads and, when 519 * nothing changed, looks as if nothing happened. 520 * 521 * @param array<string, mixed>|null $status What status() returned. 522 * @return array{0: string, 1: string} Type and message, as for notice(). 523 */ 524 public static function refresh_notice( $status ) { 525 if ( ! is_array( $status ) ) { 526 return array( 'warning', __( 'There is nothing to check yet: this site is not connected to Varly.', 'varly' ) ); 527 } 528 if ( empty( $status['reached'] ) ) { 529 return array( 'warning', __( 'Varly could not be reached just now, so the status below was not checked. Try again in a few minutes. This does not affect your site.', 'varly' ) ); 530 } 531 return array( 'success', __( 'Checked just now. The status below is up to date.', 'varly' ) ); 496 532 } 497 533 -
varly/tags/1.4.2/includes/class-varly-order-list.php
r3842788 r3844099 165 165 */ 166 166 public static function send_now() { 167 if ( ! current_user_can( 'manage_options' ) ) { 168 wp_die( esc_html__( 'You are not allowed to do this.', 'varly' ), 403 ); 169 } 167 Varly_Connect::require_admin(); 170 168 check_admin_referer( 'varly_send_order_list' ); 171 169 if ( self::enabled() ) { -
varly/tags/1.4.2/includes/class-varly-settings.php
r3842788 r3844099 320 320 $site = self::clean_site_key( $raw_site ); 321 321 if ( '' === $site ) { 322 add_settings_error( self::OPTION, 'varly_site_key', __( 'That site key is not valid. It starts with pk_, as in the Varly snippet. Your saved site key was kept.', 'varly' ) ); 322 // "Was kept" only when there was one. 323 add_settings_error( 324 self::OPTION, 325 'varly_site_key', 326 '' !== $old['site_key'] 327 ? __( 'That site key is not valid. A site key starts with pk_. Your saved site key was kept.', 'varly' ) 328 : __( 'That site key is not valid. A site key starts with pk_. In Varly, open your site and go to Install: the site key is next to the plugin download. No site key was saved.', 'varly' ) 329 ); 323 330 } else { 324 331 $out['site_key'] = $site; … … 334 341 335 342 $raw_api = isset( $in['api_key'] ) ? trim( (string) $in['api_key'] ) : ''; 343 $bad_api = false; 336 344 if ( '' !== $raw_api ) { 337 345 $api = self::clean_api_key( $raw_api ); 338 346 if ( '' === $api ) { 339 add_settings_error( self::OPTION, 'varly_api_key', __( 'That order API key is not valid. It starts with sk_. Your saved key was kept.', 'varly' ) );347 $bad_api = true; 340 348 } else { 341 349 $out['api_key'] = $api; … … 345 353 // An order API key works for one site only: the saved one belongs to the old site. 346 354 $out['api_key'] = ''; 355 } 356 if ( $bad_api ) { 357 // "Was kept" only when there is still one (see above: not after another site key). 358 add_settings_error( 359 self::OPTION, 360 'varly_api_key', 361 '' !== $out['api_key'] 362 ? __( 'That order API key is not valid. An order API key starts with sk_. Your saved order API key was kept.', 'varly' ) 363 : __( 'That order API key is not valid. An order API key starts with sk_. In Varly, open your site and go to Install → Connect your orders to create one. No order API key was saved.', 'varly' ) 364 ); 347 365 } 348 366 -
varly/tags/1.4.2/includes/class-varly-woocommerce.php
r3842788 r3844099 837 837 self::schedule( (int) $order_id, $attempt + 1, $minutes * MINUTE_IN_SECONDS ); 838 838 /* translators: 1: reason, 2: minutes. */ 839 $order->add_order_note( sprintf( __( 'Varly: sending the order failed (%1$s). It will be tried again in %2$d minutes.', 'varly' ), $why, $minutes ) );839 $order->add_order_note( sprintf( __( 'Varly: this order could not be sent yet (%1$s). The plugin tries again in %2$d minutes, so you don’t need to do anything.', 'varly' ), $why, $minutes ) ); 840 840 } elseif ( 401 === $code ) { 841 841 $order->add_order_note( __( 'Varly: the order API key was not accepted. Open Settings → Varly and click Connect to Varly again.', 'varly' ) ); -
varly/tags/1.4.2/readme.txt
r3842788 r3844099 5 5 Tested up to: 7.1 6 6 Requires PHP: 7.4 7 Stable tag: 1.4. 17 Stable tag: 1.4.2 8 8 License: GPLv2 or later 9 9 License URI: https://www.gnu.org/licenses/gpl-2.0.html … … 52 52 2. Go to Settings → Varly and click **Connect to Varly**. 53 53 3. Log in to Varly if you aren't already, pick your site and click Connect. With WooCommerce, an owner in Varly can also choose to send orders. 54 4. You're back in WordPress. In Varly, turn tracking on under Install , then open your site in a private window and accept cookies. Settings → Varly shows when the first visit arrives.54 4. You're back in WordPress. In Varly, turn tracking on under Install. Varly waits until a visitor accepts cookies in your cookie banner (unless you set that differently in Varly), so make sure your site has a cookie banner. Then open your site in a private window and accept cookies. Settings → Varly shows when the first visit arrives. 55 55 56 56 If you use a caching plugin, clear its cache once after connecting. … … 69 69 70 70 Varly only lists sites whose domains include your WordPress address, so a site can't be connected to the wrong place. In Varly, add the domain under Settings → Tracking & privacy → Domains, then click Check again on the Connect page. 71 72 = Varly shows no visits = 73 74 Check three things. Tracking is on in Varly: open your site there and look under Install. Your site has a cookie banner: Varly waits until a visitor accepts cookies, so without a banner nobody can accept and nothing is measured (the next question names the exceptions). And you accepted cookies yourself: open your site in a private window, accept cookies in the banner, and a few minutes later click Check status again under Settings → Varly. The line Data in Varly on that page tells you which of these it is. 71 75 72 76 = Does Varly set cookies before a visitor accepts? = … … 119 123 Safari deletes cookies and storage written by scripts after 7 days. A visitor who comes back later is a new visitor to Varly and can see the other version of a running test. From version 1.3.0 your own site can keep a copy of Varly's visitor ID in a cookie it sets itself, `_varly_keep` (one year). Cookies set by a site's own server are not deleted after 7 days. 120 124 121 It is off until you turn it on: in Varly, open Settings → A/B testingand tick "Recognize returning Safari visitors for longer than 7 days". It sets one more cookie after consent, so add `_varly_keep` to your cookie list first. The copy is only made for visitors who accepted cookies, and removed when they decline. The Varly snippet asks your site for it only in Safari and only while the copy is missing, at an address of its own (`/wp-json/varly/v1/keep`) that is never served from a page cache. Settings → Varly in WordPress shows whether it is on.125 It is off until you turn it on: in Varly, open Settings → Tracking & privacy and tick "Recognize returning Safari visitors for longer than 7 days". It sets one more cookie after consent, so add `_varly_keep` to your cookie list first. The copy is only made for visitors who accepted cookies, and removed when they decline. The Varly snippet asks your site for it only in Safari and only while the copy is missing, at an address of its own (`/wp-json/varly/v1/keep`) that is never served from a page cache. Settings → Varly in WordPress shows whether it is on. 122 126 123 127 = What does "hide before the page is drawn" do? = … … 151 155 == Changelog == 152 156 157 = 1.4.2 = 158 * Fixed: with a site key that Varly does not know, Settings → Varly no longer shows a green Snippet line. It says the snippet is added but does nothing yet, and what to check. 159 * Check again is now called Check status again, and tells you that it checked. 160 * Clearer messages after Disconnect and for a key that is not valid, and clearer help with the order API key and with longer recognition in Safari (you set that in Varly under Settings → Tracking & privacy). 161 * The Save Changes button and the Settings link on the Plugins screen follow the language of your WordPress admin. 162 153 163 = 1.4.1 = 154 164 * Settings → Varly now says so when your site has no cookie banner the plugin can find: Varly only measures visitors who accept cookies, so without a banner nothing is measured. … … 159 169 * The add-to-cart events and order linking now also work from the cart page. 160 170 161 = 1.3.1 = 162 * The readme now says the same everywhere about which orders are sent, when, and with which fields. 163 * Fixed: on a shop in more than one language with TranslatePress (or another plugin that puts the language in the address), orders placed on the pages of another language were not sent to Varly. 164 * Fixed: a refund that is deleted again, an order edited after payment (an item added or removed) and an order paid into a status of another plugin now update the order in Varly. So does an order deleted for good outside WooCommerce. 165 * Fixed: after Connect to Varly with another site, a refund or status change of an order sent to the old site no longer arrives in the new site as a new order. Settings → Varly no longer shows the old site's last order, and the new site gets its order list right away. 166 * Fixed: with Complianz, CookieYes, Borlabs Cookie or the WP Consent API, an order is linked to the visit only when the visitor's stored choice is yes, also when they say no on the checkout itself. 167 * Fixed: Disconnect on a staging copy of your shop no longer stops the order API key that your live shop uses. 168 * Changed: deleting the plugin also stops its order API key in Varly, and deactivating it removes its background tasks. 169 170 = 1.3.0 = 171 * New: with "Hide only the parts a test changes, before the page is drawn" chosen in Varly (Settings → A/B testing, off by default), the plugin puts a short list and a small script in the page head. The parts of a page that a running A/B test changes then stay invisible from the first moment until Varly has loaded, for at most 1.5 seconds. Never the whole page, unless you choose that in Varly. 172 * New: returning visitors in Safari can be recognized for longer than 7 days. Turn it on in Varly (Settings → A/B testing; off by default). Your site then keeps a copy of Varly's visitor ID in a cookie it sets itself (`_varly_keep`, one year), only for visitors who accepted cookies. 173 * The cookie list for the WP Consent API also names `_varly_keep`. 174 175 = 1.2.1 = 176 * Fixed: a copy of your site on another address, such as a staging site, no longer sends its orders or its order list to Varly. Settings → Varly says so on the copy. Did your shop move to a new address? Click Connect to Varly again. 177 * Fixed: an order moved to the trash or deleted no longer counts as an order in Varly, and the revenue check sees orders in the trash. 178 * Fixed: orders made by hand in the WordPress admin, by a point of sale or as a subscription renewal are sent as such, so Varly counts only web shop orders as conversions. 179 * Fixed: a survey on the order received page now also works when that page has another address than /checkout/order-received: Connect to Varly tells Varly the address your shop uses. Click Connect to Varly again once to switch it on. 180 * Fixed: when sending the daily order list fails, the next list also holds the changes of the days that failed. 181 * Fixed: the older banner of CookieYes (before version 3) is read too. 182 * Changed: once a day the plugin asks Varly whether the snippet waits for consent on your site, and empties the page cache when that changed. 183 184 = 1.2.0 = 185 * New: revenue check. Once a day the plugin sends your order list (number, time, amounts and status per order) so Varly can compare its revenue with your shop and name the cause of every difference. Settings → Varly shows when the list was last sent, with Send order list to Varly now. 186 * New: the plugin reads the visitor's choice from Complianz, CookieYes and Borlabs Cookie itself, also without Google Consent Mode. A returning visitor is recognized right away, and Varly's cookies are removed when a visitor declines. 187 * New: with privacy mode on in Varly, orders of visitors who haven't accepted cookies count in your A/B tests. Their anonymous ID travels in the checkout form, without a cookie, and never with Do Not Track or Global Privacy Control. 188 * New: the order received page has a place for a Varly survey (`#varly-survey-thank-you`) and passes the order total and number of items to survey rules. Nothing is sent by this. 189 * Fixed: when a visitor accepts cookies and goes straight to the checkout, the order is linked to the visit. 190 * Fixed: an order made by copying an earlier order, such as a subscription renewal, is no longer linked to the visit of the first order. 191 * Fixed: when the payment of an order fails after the order was sent, it no longer counts as an order in Varly. 192 * More speed plugins leave the snippet alone: FlyingPress, Breeze, NitroPack, and Delay JavaScript in WP-Optimize. 193 * The cookie list for the WP Consent API also names the visit cookie `_varly_s`. 194 195 = 1.1.0 = 196 * New: Connect to Varly. Pick your site in Varly instead of copying keys. 197 * New: the settings page shows whether Varly receives visits and orders, with Check again. 198 * New: works on any WordPress site, with or without WooCommerce. 199 * New: add-to-cart events for A/B test goals and funnels (WooCommerce). 200 * New: option to leave out visits by logged-in administrators and shop managers. 201 * New: WP Consent API support. 202 * New: more caching and speed plugins leave the snippet alone: W3 Total Cache, SiteGround Speed Optimizer, Perfmatters, Hummingbird, WP-Optimize, WP Fastest Cache. 203 * Changed: the snippet is no longer added to the cart and checkout, also when they have another address. 204 * Changed: an order that can't be sent is tried again automatically, up to 5 times. 205 * Changed: deleting the plugin also removes the Varly fields on orders and pending background tasks. 206 * Changed: Disconnect also stops the order API key in Varly. 207 * Cookie banners with automatic blocking (Cookiebot, Complianz) leave the snippet alone only when Varly does nothing before consent on your site; otherwise they keep blocking it, as with 1.0. 208 209 = 1.0.1 = 210 * After a visitor declines or withdraws cookie consent, new orders are no longer linked to their earlier visit. 211 * Tested with the block checkout and the classic checkout. 212 * Caching and speed plugins (WP Rocket, LiteSpeed Cache, Autoptimize, Cloudflare Rocket Loader, Jetpack Boost) no longer delay or combine the Varly snippet. 213 214 = 1.0.0 = 215 * First version. 171 = 1.0.0 to 1.3.1 = 172 * 1.3: two optional settings in Varly, both off until you turn them on: hide the parts a test changes before the page is drawn, and recognize returning Safari visitors for longer than 7 days (cookie `_varly_keep`). 173 * 1.2: the revenue check with a daily order list, reading the visitor's choice from Complianz, CookieYes and Borlabs Cookie, and orders of visitors in privacy mode. A copy of your shop on another address, such as a staging site, sends no orders. 174 * 1.1: Connect to Varly, a settings page that shows whether visits and orders arrive, use on any WordPress site with or without WooCommerce, and add-to-cart events. 175 * 1.0: first version. 216 176 217 177 == Upgrade Notice == 178 179 = 1.4.2 = 180 Settings → Varly is clearer: a site key that Varly does not know no longer looks fine, and Check status again tells you that it checked. 218 181 219 182 = 1.4.1 = -
varly/tags/1.4.2/varly.php
r3842788 r3844099 4 4 * Plugin URI: https://varly.ai/help/install-woocommerce-wordpress 5 5 * Description: Heatmaps, recordings, surveys and A/B tests by Varly. Adds the Varly snippet to your site and, with WooCommerce, sends your orders to Varly. 6 * Version: 1.4. 16 * Version: 1.4.2 7 7 * Requires at least: 6.3 8 8 * Requires PHP: 7.4 … … 35 35 } 36 36 37 define( 'VARLY_VERSION', '1.4. 1' );37 define( 'VARLY_VERSION', '1.4.2' ); 38 38 define( 'VARLY_FILE', __FILE__ ); 39 39 define( 'VARLY_DIR', plugin_dir_path( __FILE__ ) ); -
varly/trunk/includes/class-varly-admin.php
r3842788 r3844099 68 68 69 69 /** 70 * "Settings" next to Deactivate on the Plugins screen. 70 * "Settings" next to Deactivate on the Plugins screen. The word is WordPress's own, without a text 71 * domain, so it is in the language of the admin right away. 71 72 * 72 73 * @param string[] $links Links. … … 74 75 */ 75 76 public static function action_links( $links ) { 76 array_unshift( $links, '<a href="' . esc_url( Varly_Connect::settings_url() ) . '">' . esc_html__( 'Settings', 'varly' ) . '</a>' ); 77 // phpcs:ignore WordPress.WP.I18n.MissingArgDomain -- On purpose: WordPress's own translation of "Settings". 78 array_unshift( $links, '<a href="' . esc_url( Varly_Connect::settings_url() ) . '">' . esc_html__( 'Settings' ) . '</a>' ); 77 79 return $links; 78 80 } … … 153 155 public static function no_visits_text() { 154 156 if ( Varly_Settings::consent_gated() && array() === Varly_Consent::tools() ) { 155 return __( 'No visits in the last 24 hours. Varly only measures visitors who accept cookies, and this plugin found no cookie banner on your site. Without a banner, nobody can accept, so nothing is measured. Add a cookie banner, for example Complianz or CookieYes. Using another banner? Open your site in a private window and accept cookies; the visit shows up here within a few minutes (click Check again).', 'varly' );156 } 157 return __( 'No visits in the last 24 hours. Open your site in a private window and accept cookies; the visit shows up here within a few minutes (click Check again).', 'varly' );157 return __( 'No visits in the last 24 hours. Varly only measures visitors who accept cookies, and this plugin found no cookie banner on your site. Without a banner, nobody can accept, so nothing is measured. Add a cookie banner, for example Complianz or CookieYes. Using another banner? Open your site in a private window and accept cookies; the visit shows up here within a few minutes (click Check status again).', 'varly' ); 158 } 159 return __( 'No visits in the last 24 hours. Open your site in a private window and accept cookies; the visit shows up here within a few minutes (click Check status again).', 'varly' ); 158 160 } 159 161 … … 178 180 ); 179 181 180 if ( '1' === $settings['snippet'] ) { 182 // Varly answered and does not know the site key (a typing mistake, or the site was deleted in 183 // Varly): the snippet tag is on the site, but there is no script behind it. 184 $unknown = is_array( $status ) && $status['reached'] && ! $status['known']; 185 186 if ( '1' === $settings['snippet'] && $unknown ) { 187 self::status_row( __( 'Snippet', 'varly' ), 'warning', __( 'Added to every page, but Varly does not know this site key, so the snippet does nothing yet.', 'varly' ) ); 188 } elseif ( '1' === $settings['snippet'] ) { 181 189 self::status_row( __( 'Snippet', 'varly' ), 'ok', ( '1' === Varly_Settings::value( 'skip_checkout' ) && Varly_WooCommerce::active() ? __( 'Added to the top of every page, except the checkout (you left it out below).', 'varly' ) : __( 'Added to the top of every page, including the cart and checkout.', 'varly' ) ) ); 182 190 } else { … … 186 194 if ( ! is_array( $status ) || ! $status['reached'] ) { 187 195 self::status_row( __( 'Data in Varly', 'varly' ), 'info', __( 'Could not reach Varly to check right now. This does not affect your site.', 'varly' ) ); 188 } elseif ( ! $status['known']) {189 self::status_row( __( 'Data in Varly', 'varly' ), 'error', __( 'Varly does not know this site key. Click Connect to Varly again .', 'varly' ) );196 } elseif ( $unknown ) { 197 self::status_row( __( 'Data in Varly', 'varly' ), 'error', __( 'Varly does not know this site key. Click Connect to Varly again, or check the site key under Enter keys yourself.', 'varly' ) ); 190 198 } elseif ( ! $status['tracking'] ) { 191 199 self::status_row( __( 'Data in Varly', 'varly' ), 'warning', __( 'Tracking is off in Varly, so nothing is measured yet. In Varly, open your site and click Turn tracking on under Install.', 'varly' ) ); … … 214 222 } elseif ( ! empty( $state['last_sent'] ) ) { 215 223 /* translators: 1: order number, 2: "5 minutes ago". */ 216 self::status_row( __( 'Orders', 'varly' ), 'ok', sprintf( __( 'Sent to Varly in the background. The last one, order %1$s, w ent %2$s.', 'varly' ), $state['last_order'], self::ago( (int) $state['last_sent'] ) ) );224 self::status_row( __( 'Orders', 'varly' ), 'ok', sprintf( __( 'Sent to Varly in the background. The last one, order %1$s, was sent %2$s.', 'varly' ), $state['last_order'], self::ago( (int) $state['last_sent'] ) ) ); 217 225 } else { 218 226 self::status_row( __( 'Orders', 'varly' ), 'ok', __( 'Ready. Every paid order is sent to Varly in the background; refunds and cancellations update it.', 'varly' ) ); … … 243 251 return; 244 252 } 253 // First what Varly says (kept for two minutes): it can change a setting shown below, such as 254 // longer recognition in Safari. 255 Varly_Connect::status(); 245 256 $settings = Varly_Settings::get(); 246 257 $connected = Varly_Settings::connected(); … … 283 294 </table> 284 295 <div class="varly-actions"> 285 <?php self::action_button( 'varly_refresh_status', __( 'Check again', 'varly' ) ); ?>296 <?php self::action_button( 'varly_refresh_status', __( 'Check status again', 'varly' ) ); ?> 286 297 <?php self::action_button( 'varly_connect', __( 'Connect to Varly again', 'varly' ) ); ?> 287 298 <?php if ( Varly_Order_List::enabled() ) : ?> … … 326 337 <th scope="row"><?php esc_html_e( 'Returning visitors in Safari', 'varly' ); ?></th> 327 338 <td> 328 <p><strong><?php echo esc_html( '1' === $settings['keep'] ? __( 'On: recognized for up to a year', 'varly' ) : __( 'Off: recognized for 7 days', 'varly' ) ); ?></strong></p> 329 <p class="description"><?php esc_html_e( 'Safari deletes cookies set by scripts after 7 days, so a visitor who comes back later can get the other version of a running test. You turn this on or off in Varly, under Settings → A/B testing. When it is on, your site keeps a copy of Varly’s visitor ID in a cookie it sets itself (_varly_keep, one year), only for visitors who accepted cookies, and removes it when they decline. Add _varly_keep to your cookie list before you turn it on.', 'varly' ); ?></p> 339 <?php // Information only: this is set in Varly (Settings → Tracking & privacy), so there is no box to tick here. ?> 340 <?php if ( '1' === $settings['keep'] ) : ?> 341 <p><?php esc_html_e( 'On. You turn this off in Varly, under Settings → Tracking & privacy.', 'varly' ); ?></p> 342 <p class="description"><?php esc_html_e( 'Safari forgets a visitor after 7 days, so someone who comes back later could see the other version of a running test. With this on, Varly recognizes them for up to a year. Your site sets one cookie for it, _varly_keep (kept for one year), only for visitors who accepted cookies. Make sure it is on your cookie list.', 'varly' ); ?></p> 343 <?php else : ?> 344 <p><?php esc_html_e( 'Off. You turn this on in Varly, under Settings → Tracking & privacy.', 'varly' ); ?></p> 345 <p class="description"><?php esc_html_e( 'Safari forgets a visitor after 7 days, so someone who comes back later can see the other version of a running test. With this on, Varly recognizes them for up to a year. Your site then sets one cookie, _varly_keep (kept for one year), only for visitors who accepted cookies. Add it to your cookie list before you turn this on.', 'varly' ); ?></p> 346 <?php endif; ?> 330 347 </td> 331 348 </tr> … … 348 365 <td> 349 366 <input id="varly_api_key" name="<?php echo esc_attr( $option ); ?>[api_key]" type="password" class="regular-text code" value="" autocomplete="new-password" spellcheck="false" placeholder="<?php echo esc_attr( '' !== $settings['api_key'] ? __( 'Saved. Leave empty to keep it.', 'varly' ) : 'sk_…' ); ?>" /> 350 <p class="description"><?php esc_html_e( 'Starts with sk_. In Varly under Install → Connect your orders, an owner clicks Create API key. With it, the plugin sends every paid order to Varly.', 'varly' ); ?></p>367 <p class="description"><?php esc_html_e( 'Starts with sk_. In Varly, go to Install → Connect your orders and click Create API key (only an owner of the Varly account can do this). With this key, the plugin sends every paid order to Varly.', 'varly' ); ?></p> 351 368 </td> 352 369 </tr> … … 355 372 </details> 356 373 357 <?php submit_button( __( 'Save changes', 'varly' ) ); ?> 374 <?php // WordPress's own "Save Changes", in the language of the admin. ?> 375 <?php submit_button(); ?> 358 376 </form> 359 377 -
varly/trunk/includes/class-varly-connect.php
r3842788 r3844099 172 172 173 173 /** 174 * Only administrators of this site. 175 * 176 * @return void 177 */ 178 p rivatestatic function require_admin() {174 * Only administrators of this site. One message for every button on Settings → Varly. 175 * 176 * @return void 177 */ 178 public static function require_admin() { 179 179 if ( ! current_user_can( 'manage_options' ) ) { 180 180 wp_die( esc_html__( 'You need to be an administrator of this site to do this.', 'varly' ), 403 ); … … 448 448 ); 449 449 Varly_Compat::purge_page_cache(); 450 if ( $had_key && $copy ) { 451 self::notice( 'success', __( 'Disconnected. The Varly snippet is no longer on this site, and it sends no orders. This site looked like a copy, so the order API key keeps working for the site it was first connected on.', 'varly' ) ); 452 } elseif ( $had_key && ! $revoked ) { 453 self::notice( 'warning', __( 'Disconnected. The Varly snippet is no longer on your site, and orders are no longer sent. Varly could not be reached to stop the order API key: it keeps working in Varly until you create a new one under Install → Connect your orders.', 'varly' ) ); 454 } else { 455 self::notice( 'success', __( 'Disconnected. The Varly snippet is no longer on your site, and orders are no longer sent to Varly.', 'varly' ) ); 456 } 450 $notice = self::disconnect_notice( $had_key, $copy, $revoked ); 451 self::notice( $notice[0], $notice[1] ); 457 452 self::back(); 453 } 454 455 /** 456 * What Settings → Varly says after Disconnect. Orders are only mentioned when this site had an 457 * order API key: without one it never sent any. 458 * 459 * @param bool $had_key An order API key was saved. 460 * @param bool $copy This site looked like a copy (see Varly_Settings::is_copy()). 461 * @param bool $revoked Varly confirmed that the order API key stopped. 462 * @return array{0: string, 1: string} Type and message, as for notice(). 463 */ 464 public static function disconnect_notice( $had_key, $copy, $revoked ) { 465 if ( ! $had_key ) { 466 return array( 'success', __( 'Disconnected. The Varly snippet is no longer on your site.', 'varly' ) ); 467 } 468 if ( $copy ) { 469 return array( 'success', __( 'Disconnected. The Varly snippet is no longer on this site, and it sends no orders. This site looked like a copy, so the order API key keeps working for the site it was first connected on.', 'varly' ) ); 470 } 471 if ( ! $revoked ) { 472 return array( 'warning', __( 'Disconnected. The Varly snippet is no longer on your site, and orders are no longer sent. Varly could not be reached to stop the order API key: it keeps working in Varly until you create a new one under Install → Connect your orders.', 'varly' ) ); 473 } 474 return array( 'success', __( 'Disconnected. The Varly snippet is no longer on your site, and orders are no longer sent to Varly.', 'varly' ) ); 458 475 } 459 476 … … 485 502 486 503 /** 487 * "Check again": fetch the status from Varly now.504 * "Check status again": fetch the status from Varly now, and say that it happened. 488 505 * 489 506 * @return void … … 493 510 check_admin_referer( 'varly_refresh_status' ); 494 511 delete_transient( self::STATUS_TRANSIENT ); 512 $notice = self::refresh_notice( self::status() ); 513 self::notice( $notice[0], $notice[1] ); 495 514 self::back(); 515 } 516 517 /** 518 * What Settings → Varly says after Check status again. Without it the page reloads and, when 519 * nothing changed, looks as if nothing happened. 520 * 521 * @param array<string, mixed>|null $status What status() returned. 522 * @return array{0: string, 1: string} Type and message, as for notice(). 523 */ 524 public static function refresh_notice( $status ) { 525 if ( ! is_array( $status ) ) { 526 return array( 'warning', __( 'There is nothing to check yet: this site is not connected to Varly.', 'varly' ) ); 527 } 528 if ( empty( $status['reached'] ) ) { 529 return array( 'warning', __( 'Varly could not be reached just now, so the status below was not checked. Try again in a few minutes. This does not affect your site.', 'varly' ) ); 530 } 531 return array( 'success', __( 'Checked just now. The status below is up to date.', 'varly' ) ); 496 532 } 497 533 -
varly/trunk/includes/class-varly-order-list.php
r3842788 r3844099 165 165 */ 166 166 public static function send_now() { 167 if ( ! current_user_can( 'manage_options' ) ) { 168 wp_die( esc_html__( 'You are not allowed to do this.', 'varly' ), 403 ); 169 } 167 Varly_Connect::require_admin(); 170 168 check_admin_referer( 'varly_send_order_list' ); 171 169 if ( self::enabled() ) { -
varly/trunk/includes/class-varly-settings.php
r3842788 r3844099 320 320 $site = self::clean_site_key( $raw_site ); 321 321 if ( '' === $site ) { 322 add_settings_error( self::OPTION, 'varly_site_key', __( 'That site key is not valid. It starts with pk_, as in the Varly snippet. Your saved site key was kept.', 'varly' ) ); 322 // "Was kept" only when there was one. 323 add_settings_error( 324 self::OPTION, 325 'varly_site_key', 326 '' !== $old['site_key'] 327 ? __( 'That site key is not valid. A site key starts with pk_. Your saved site key was kept.', 'varly' ) 328 : __( 'That site key is not valid. A site key starts with pk_. In Varly, open your site and go to Install: the site key is next to the plugin download. No site key was saved.', 'varly' ) 329 ); 323 330 } else { 324 331 $out['site_key'] = $site; … … 334 341 335 342 $raw_api = isset( $in['api_key'] ) ? trim( (string) $in['api_key'] ) : ''; 343 $bad_api = false; 336 344 if ( '' !== $raw_api ) { 337 345 $api = self::clean_api_key( $raw_api ); 338 346 if ( '' === $api ) { 339 add_settings_error( self::OPTION, 'varly_api_key', __( 'That order API key is not valid. It starts with sk_. Your saved key was kept.', 'varly' ) );347 $bad_api = true; 340 348 } else { 341 349 $out['api_key'] = $api; … … 345 353 // An order API key works for one site only: the saved one belongs to the old site. 346 354 $out['api_key'] = ''; 355 } 356 if ( $bad_api ) { 357 // "Was kept" only when there is still one (see above: not after another site key). 358 add_settings_error( 359 self::OPTION, 360 'varly_api_key', 361 '' !== $out['api_key'] 362 ? __( 'That order API key is not valid. An order API key starts with sk_. Your saved order API key was kept.', 'varly' ) 363 : __( 'That order API key is not valid. An order API key starts with sk_. In Varly, open your site and go to Install → Connect your orders to create one. No order API key was saved.', 'varly' ) 364 ); 347 365 } 348 366 -
varly/trunk/includes/class-varly-woocommerce.php
r3842788 r3844099 837 837 self::schedule( (int) $order_id, $attempt + 1, $minutes * MINUTE_IN_SECONDS ); 838 838 /* translators: 1: reason, 2: minutes. */ 839 $order->add_order_note( sprintf( __( 'Varly: sending the order failed (%1$s). It will be tried again in %2$d minutes.', 'varly' ), $why, $minutes ) );839 $order->add_order_note( sprintf( __( 'Varly: this order could not be sent yet (%1$s). The plugin tries again in %2$d minutes, so you don’t need to do anything.', 'varly' ), $why, $minutes ) ); 840 840 } elseif ( 401 === $code ) { 841 841 $order->add_order_note( __( 'Varly: the order API key was not accepted. Open Settings → Varly and click Connect to Varly again.', 'varly' ) ); -
varly/trunk/readme.txt
r3842788 r3844099 5 5 Tested up to: 7.1 6 6 Requires PHP: 7.4 7 Stable tag: 1.4. 17 Stable tag: 1.4.2 8 8 License: GPLv2 or later 9 9 License URI: https://www.gnu.org/licenses/gpl-2.0.html … … 52 52 2. Go to Settings → Varly and click **Connect to Varly**. 53 53 3. Log in to Varly if you aren't already, pick your site and click Connect. With WooCommerce, an owner in Varly can also choose to send orders. 54 4. You're back in WordPress. In Varly, turn tracking on under Install , then open your site in a private window and accept cookies. Settings → Varly shows when the first visit arrives.54 4. You're back in WordPress. In Varly, turn tracking on under Install. Varly waits until a visitor accepts cookies in your cookie banner (unless you set that differently in Varly), so make sure your site has a cookie banner. Then open your site in a private window and accept cookies. Settings → Varly shows when the first visit arrives. 55 55 56 56 If you use a caching plugin, clear its cache once after connecting. … … 69 69 70 70 Varly only lists sites whose domains include your WordPress address, so a site can't be connected to the wrong place. In Varly, add the domain under Settings → Tracking & privacy → Domains, then click Check again on the Connect page. 71 72 = Varly shows no visits = 73 74 Check three things. Tracking is on in Varly: open your site there and look under Install. Your site has a cookie banner: Varly waits until a visitor accepts cookies, so without a banner nobody can accept and nothing is measured (the next question names the exceptions). And you accepted cookies yourself: open your site in a private window, accept cookies in the banner, and a few minutes later click Check status again under Settings → Varly. The line Data in Varly on that page tells you which of these it is. 71 75 72 76 = Does Varly set cookies before a visitor accepts? = … … 119 123 Safari deletes cookies and storage written by scripts after 7 days. A visitor who comes back later is a new visitor to Varly and can see the other version of a running test. From version 1.3.0 your own site can keep a copy of Varly's visitor ID in a cookie it sets itself, `_varly_keep` (one year). Cookies set by a site's own server are not deleted after 7 days. 120 124 121 It is off until you turn it on: in Varly, open Settings → A/B testingand tick "Recognize returning Safari visitors for longer than 7 days". It sets one more cookie after consent, so add `_varly_keep` to your cookie list first. The copy is only made for visitors who accepted cookies, and removed when they decline. The Varly snippet asks your site for it only in Safari and only while the copy is missing, at an address of its own (`/wp-json/varly/v1/keep`) that is never served from a page cache. Settings → Varly in WordPress shows whether it is on.125 It is off until you turn it on: in Varly, open Settings → Tracking & privacy and tick "Recognize returning Safari visitors for longer than 7 days". It sets one more cookie after consent, so add `_varly_keep` to your cookie list first. The copy is only made for visitors who accepted cookies, and removed when they decline. The Varly snippet asks your site for it only in Safari and only while the copy is missing, at an address of its own (`/wp-json/varly/v1/keep`) that is never served from a page cache. Settings → Varly in WordPress shows whether it is on. 122 126 123 127 = What does "hide before the page is drawn" do? = … … 151 155 == Changelog == 152 156 157 = 1.4.2 = 158 * Fixed: with a site key that Varly does not know, Settings → Varly no longer shows a green Snippet line. It says the snippet is added but does nothing yet, and what to check. 159 * Check again is now called Check status again, and tells you that it checked. 160 * Clearer messages after Disconnect and for a key that is not valid, and clearer help with the order API key and with longer recognition in Safari (you set that in Varly under Settings → Tracking & privacy). 161 * The Save Changes button and the Settings link on the Plugins screen follow the language of your WordPress admin. 162 153 163 = 1.4.1 = 154 164 * Settings → Varly now says so when your site has no cookie banner the plugin can find: Varly only measures visitors who accept cookies, so without a banner nothing is measured. … … 159 169 * The add-to-cart events and order linking now also work from the cart page. 160 170 161 = 1.3.1 = 162 * The readme now says the same everywhere about which orders are sent, when, and with which fields. 163 * Fixed: on a shop in more than one language with TranslatePress (or another plugin that puts the language in the address), orders placed on the pages of another language were not sent to Varly. 164 * Fixed: a refund that is deleted again, an order edited after payment (an item added or removed) and an order paid into a status of another plugin now update the order in Varly. So does an order deleted for good outside WooCommerce. 165 * Fixed: after Connect to Varly with another site, a refund or status change of an order sent to the old site no longer arrives in the new site as a new order. Settings → Varly no longer shows the old site's last order, and the new site gets its order list right away. 166 * Fixed: with Complianz, CookieYes, Borlabs Cookie or the WP Consent API, an order is linked to the visit only when the visitor's stored choice is yes, also when they say no on the checkout itself. 167 * Fixed: Disconnect on a staging copy of your shop no longer stops the order API key that your live shop uses. 168 * Changed: deleting the plugin also stops its order API key in Varly, and deactivating it removes its background tasks. 169 170 = 1.3.0 = 171 * New: with "Hide only the parts a test changes, before the page is drawn" chosen in Varly (Settings → A/B testing, off by default), the plugin puts a short list and a small script in the page head. The parts of a page that a running A/B test changes then stay invisible from the first moment until Varly has loaded, for at most 1.5 seconds. Never the whole page, unless you choose that in Varly. 172 * New: returning visitors in Safari can be recognized for longer than 7 days. Turn it on in Varly (Settings → A/B testing; off by default). Your site then keeps a copy of Varly's visitor ID in a cookie it sets itself (`_varly_keep`, one year), only for visitors who accepted cookies. 173 * The cookie list for the WP Consent API also names `_varly_keep`. 174 175 = 1.2.1 = 176 * Fixed: a copy of your site on another address, such as a staging site, no longer sends its orders or its order list to Varly. Settings → Varly says so on the copy. Did your shop move to a new address? Click Connect to Varly again. 177 * Fixed: an order moved to the trash or deleted no longer counts as an order in Varly, and the revenue check sees orders in the trash. 178 * Fixed: orders made by hand in the WordPress admin, by a point of sale or as a subscription renewal are sent as such, so Varly counts only web shop orders as conversions. 179 * Fixed: a survey on the order received page now also works when that page has another address than /checkout/order-received: Connect to Varly tells Varly the address your shop uses. Click Connect to Varly again once to switch it on. 180 * Fixed: when sending the daily order list fails, the next list also holds the changes of the days that failed. 181 * Fixed: the older banner of CookieYes (before version 3) is read too. 182 * Changed: once a day the plugin asks Varly whether the snippet waits for consent on your site, and empties the page cache when that changed. 183 184 = 1.2.0 = 185 * New: revenue check. Once a day the plugin sends your order list (number, time, amounts and status per order) so Varly can compare its revenue with your shop and name the cause of every difference. Settings → Varly shows when the list was last sent, with Send order list to Varly now. 186 * New: the plugin reads the visitor's choice from Complianz, CookieYes and Borlabs Cookie itself, also without Google Consent Mode. A returning visitor is recognized right away, and Varly's cookies are removed when a visitor declines. 187 * New: with privacy mode on in Varly, orders of visitors who haven't accepted cookies count in your A/B tests. Their anonymous ID travels in the checkout form, without a cookie, and never with Do Not Track or Global Privacy Control. 188 * New: the order received page has a place for a Varly survey (`#varly-survey-thank-you`) and passes the order total and number of items to survey rules. Nothing is sent by this. 189 * Fixed: when a visitor accepts cookies and goes straight to the checkout, the order is linked to the visit. 190 * Fixed: an order made by copying an earlier order, such as a subscription renewal, is no longer linked to the visit of the first order. 191 * Fixed: when the payment of an order fails after the order was sent, it no longer counts as an order in Varly. 192 * More speed plugins leave the snippet alone: FlyingPress, Breeze, NitroPack, and Delay JavaScript in WP-Optimize. 193 * The cookie list for the WP Consent API also names the visit cookie `_varly_s`. 194 195 = 1.1.0 = 196 * New: Connect to Varly. Pick your site in Varly instead of copying keys. 197 * New: the settings page shows whether Varly receives visits and orders, with Check again. 198 * New: works on any WordPress site, with or without WooCommerce. 199 * New: add-to-cart events for A/B test goals and funnels (WooCommerce). 200 * New: option to leave out visits by logged-in administrators and shop managers. 201 * New: WP Consent API support. 202 * New: more caching and speed plugins leave the snippet alone: W3 Total Cache, SiteGround Speed Optimizer, Perfmatters, Hummingbird, WP-Optimize, WP Fastest Cache. 203 * Changed: the snippet is no longer added to the cart and checkout, also when they have another address. 204 * Changed: an order that can't be sent is tried again automatically, up to 5 times. 205 * Changed: deleting the plugin also removes the Varly fields on orders and pending background tasks. 206 * Changed: Disconnect also stops the order API key in Varly. 207 * Cookie banners with automatic blocking (Cookiebot, Complianz) leave the snippet alone only when Varly does nothing before consent on your site; otherwise they keep blocking it, as with 1.0. 208 209 = 1.0.1 = 210 * After a visitor declines or withdraws cookie consent, new orders are no longer linked to their earlier visit. 211 * Tested with the block checkout and the classic checkout. 212 * Caching and speed plugins (WP Rocket, LiteSpeed Cache, Autoptimize, Cloudflare Rocket Loader, Jetpack Boost) no longer delay or combine the Varly snippet. 213 214 = 1.0.0 = 215 * First version. 171 = 1.0.0 to 1.3.1 = 172 * 1.3: two optional settings in Varly, both off until you turn them on: hide the parts a test changes before the page is drawn, and recognize returning Safari visitors for longer than 7 days (cookie `_varly_keep`). 173 * 1.2: the revenue check with a daily order list, reading the visitor's choice from Complianz, CookieYes and Borlabs Cookie, and orders of visitors in privacy mode. A copy of your shop on another address, such as a staging site, sends no orders. 174 * 1.1: Connect to Varly, a settings page that shows whether visits and orders arrive, use on any WordPress site with or without WooCommerce, and add-to-cart events. 175 * 1.0: first version. 216 176 217 177 == Upgrade Notice == 178 179 = 1.4.2 = 180 Settings → Varly is clearer: a site key that Varly does not know no longer looks fine, and Check status again tells you that it checked. 218 181 219 182 = 1.4.1 = -
varly/trunk/varly.php
r3842788 r3844099 4 4 * Plugin URI: https://varly.ai/help/install-woocommerce-wordpress 5 5 * Description: Heatmaps, recordings, surveys and A/B tests by Varly. Adds the Varly snippet to your site and, with WooCommerce, sends your orders to Varly. 6 * Version: 1.4. 16 * Version: 1.4.2 7 7 * Requires at least: 6.3 8 8 * Requires PHP: 7.4 … … 35 35 } 36 36 37 define( 'VARLY_VERSION', '1.4. 1' );37 define( 'VARLY_VERSION', '1.4.2' ); 38 38 define( 'VARLY_FILE', __FILE__ ); 39 39 define( 'VARLY_DIR', plugin_dir_path( __FILE__ ) );
Note:
See TracChangeset
for help on using the changeset viewer.