Plugin Directory

Changeset 2860872


Ignore:
Timestamp:
02/06/2023 02:25:00 PM (3 years ago)
Author:
comoquiero
Message:

Preparing for 23.02.061524 release

Location:
comoquiero/trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • comoquiero/trunk/comoquiero.php

    r2860841 r2860872  
    22/*
    33 * Plugin Name: Qcart
    4  * Version: 23.02.061258
     4 * Version: 23.02.061427
    55 * Author: ComoQuiero
    66 * Author URI: https://qcart.app
  • comoquiero/trunk/comoquiero.php.bu

    r2860841 r2860872  
    22/*
    33 * Plugin Name: Qcart
    4  * Version: 23.02.061252
     4 * Version: 23.02.061258
    55 * Author: ComoQuiero
    66 * Author URI: https://qcart.app
     
    1212// stackoverflow.com/questions/6127559/wordpress-plugin-call-to-undefined-function-wp-get-current-user
    1313add_action('init', function () {
     14    add_action('wp_head', "qcart_head");
    1415
    1516    if (is_admin()) {
     
    2021
    2122    // fetch("/wp-admin/admin-ajax.php?action=new", { method: "POST", body: JSON.stringify({ action: "new" }) });
    22     add_action('wp_ajax_nopriv_new', "newDomain");
     23    add_action('wp_ajax_nopriv_new', "qcart_newDomain");
    2324
    2425    // fetch("/wp-admin/admin-ajax.php?action=domain", { method: "POST", body: JSON.stringify({ action: "domain" }) });
    25     add_action('wp_ajax_nopriv_domain', "changeDomain");
     26    add_action('wp_ajax_nopriv_domain', "qcart_changeDomain");
    2627
    2728    // fetch("/wp-admin/admin-ajax.php?action=postsync", { method: "POST", body: JSON.stringify({ action: "postsync" }) });
    28     add_action('wp_ajax_nopriv_postsync', "postSync");
     29    add_action('wp_ajax_nopriv_postsync', "qcart_postSync");
    2930
    3031});
    3132
    32 function newDomain()
     33function qcart_newDomain()
    3334{
    3435    $inputJSON = file_get_contents('php://input');
     
    4344}
    4445
    45 function changeDomain()
     46function qcart_changeDomain()
    4647{
    4748    $inputJSON = file_get_contents('php://input');
     
    6061}
    6162
    62 function postSync()
     63function qcart_postSync()
    6364{
    6465    // wordpress.stackexchange.com/questions/307193/admin-ajax-php-doesnt-work-when-using-post-data-and-axios
     
    228229    //     return "<div class='$q'></div>";
    229230    // });
    230 
     231}
     232
     233function qcart_head()
     234{
    231235    // LOCATION.SEARCH
    232236    $q = "";
     
    252256    }
    253257
    254     // INJECT SCRIPT
    255     wp_enqueue_script('qcart', plugins_url("js/qcart.js?$q", __FILE__), array(), time(), true);
    256 }
     258    echo "<script>!function (e, f, u) { e.async = 1; e.src = u; f.parentNode.insertBefore(e, f); }(document.createElement('script'), document.getElementsByTagName('script')[0], 'https://qcart.app/btn.js?trg=any&$q');</script>";
     259}
  • comoquiero/trunk/readme.txt

    r2860841 r2860872  
    44Author URI: https://qcart.app
    55Tested up to: 6.1
    6 Stable tag: 23.02.061258
     6Stable tag: 23.02.061427
    77License: GPLv2 or later
    88
  • comoquiero/trunk/readme.txt.bu

    r2860841 r2860872  
    44Author URI: https://qcart.app
    55Tested up to: 6.1
    6 Stable tag: 23.02.061252
     6Stable tag: 23.02.061258
    77License: GPLv2 or later
    88
Note: See TracChangeset for help on using the changeset viewer.