Forum Replies Created

Viewing 15 replies - 1 through 15 (of 146 total)
  • @cyriac1993

    They removed IE support however it’s possible to get it to work again on IE 11.

    Add this to your themes functions.php to get the wp-admin back end to work again:

    
    function load_ie_11_trident_scripts(){ 
    	wp_deregister_script('jquery');
    	wp_enqueue_script('jquery', 'https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js');
        wp_enqueue_script('wp-polyfill-dom-rect'); 
    	wp_enqueue_script('wp-polyfill-element-closest'); 
    	wp_enqueue_script('wp-polyfill-fetch'); 
    	wp_enqueue_script('wp-polyfill-formdata'); 
    	wp_enqueue_script('wp-polyfill-node-contains'); 
    	wp_enqueue_script('wp-polyfill-object-fit'); 
    	wp_enqueue_script('wp-polyfill-url'); 
    	wp_enqueue_script('regenerator-runtime');
    }
     	add_action( 'admin_enqueue_scripts', 'load_ie_11_trident_scripts');
    

    Add this to your themes functions.php to get the front-end to work again:

    
    function load_ie_11_trident_scripts_frontend(){ 
    	wp_deregister_script('jquery');
    	wp_enqueue_script('jquery', 'https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js');
        wp_enqueue_script('wp-polyfill-dom-rect'); 
    	wp_enqueue_script('wp-polyfill-element-closest'); 
    	wp_enqueue_script('wp-polyfill-fetch'); 
    	wp_enqueue_script('wp-polyfill-formdata'); 
    	wp_enqueue_script('wp-polyfill-node-contains'); 
    	wp_enqueue_script('wp-polyfill-object-fit'); 
    	wp_enqueue_script('wp-polyfill-url'); 
    	wp_enqueue_script('regenerator-runtime');
    }
     	add_action( 'wp_enqueue_scripts', 'load_ie_11_trident_scripts_frontend');

    `

    Thread Starter kimsf

    (@kimsf)

    @noisysocks

    Adding scripts did work after other issues were dealt with.

    I finally got this resolved. It turns out that load-scripts.php is no longer IE 11/Trident friendly and will cause a JS error on line 10. This error prevents jquery from loading which makes the whole backend almost non-functional for internet explorer 11.

    For anyone else with this issue, the most elegant solution I’ve come up with is adding this code to your themes functions.php:

    function load_ie_11_trident_scripts(){ 
    	wp_deregister_script('jquery');
    	wp_enqueue_script('jquery', 'https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js');
        wp_enqueue_script('wp-polyfill-dom-rect'); 
    	wp_enqueue_script('wp-polyfill-element-closest'); 
    	wp_enqueue_script('wp-polyfill-fetch'); 
    	wp_enqueue_script('wp-polyfill-formdata'); 
    	wp_enqueue_script('wp-polyfill-node-contains'); 
    	wp_enqueue_script('wp-polyfill-object-fit'); 
    	wp_enqueue_script('wp-polyfill-url'); 
    	wp_enqueue_script('regenerator-runtime');
    }
     	add_action( 'admin_enqueue_scripts', 'load_ie_11_trident_scripts');
    

    I think that the footnote mentioning localized information under the first download is simply extra information. That footnote applies to both of the update prompts presented.

    en-CA means Canadian English version. I think the only differences are minor langauge differences such as “metre” instead of “meter”.

    I think it might have to do with how they parse and process the webpage. I went to a page and can confirm that firefox 66 and Edge 44 are downloading both webp and jpg on first load. On second load firefox doesn’t download duplicate images. It doesn’t seem to be that big of an issue since it seems to display the page first before downloading the duplicate images but I wonder how other browsers such as Safari would handle it.

    https://imgur.com/a/PHyNy2M

    I know of another site which doesn’t have the issue but it uses http2 and srcset for the jpegs. I think adding the srcset attribute for jpegs is something you can try to fix the issue. A plugin such as Regenerate Thumbnails could be used to add it.

    • This reply was modified 5 years, 8 months ago by kimsf.
    • This reply was modified 5 years, 8 months ago by kimsf.

    It appears to work just fine for PHP 7.2.11.

    To make it work with Woocommerce do the following:

    Instructions
    1. You’ll first need to go to /wp-content/plugins/woocommerce/includes
    2. Open file wc-user-functions.php in that directory
    3. Change the following

    FROM:

    if ( email_exists( $email ) ) {
    return new WP_Error( ‘registration-error-email-exists’, __( ‘An account is already registered with your email address. Please login.’, ‘woocommerce’ ) );
    }

    TO:

    if ( email_exists( $email ) ) {

    }

    If you don’t do this users will be given an error message after they’ve entered all of their information and credit card to check out. Then when it doesn’t work they are confused. Woocommerce should have the OPTION of allowing multiple accounts. There aren’t any issues with coupons. I would love customers to keep ordering again and again if it means using the same coupon. Also the recover password works as well which allows for a username OR email to recover password. When an email is entered it will recover the last account I believe. If a username is entered then it still recovers the account. So it always works.

    Now everytime you update woocommerce you’ll need to update wc-user-functions.php again and also make sure permissions are set correctly if using SSH to edit it. Also a good idea to backup site.

    • This reply was modified 6 years, 4 months ago by kimsf.
    • This reply was modified 6 years, 4 months ago by kimsf. Reason: tags not working
    • This reply was modified 6 years, 4 months ago by kimsf.

    You can also check what username and group the folders belong to. If you uploaded the plugin via FTP or moved the folder using SSH it can copy it with the wrong username and group permissions.

    1) In case anyone else is wondering to requeue you can type something like this in SSH (varies). You need to move the files from failed sent to the email queue.

    cd /var/www/html/wp-content/uploads/smtp-mailing-queue/invalid
    Move to the directory – your directory might be different than this.

    pwd
    You want to verify and make sure you’re at the directory. pwd shows current path.

    sudo find . -maxdepth 1 -exec mv {} .. \;
    Again make sure you’re in the correct directory. This will move all files from current directory to one level up. It should show an error but that’s ok. Also a good idea to back up regularly.

    2) Emails seem to fail to send if there is another cronjob being ran at the same time. I don’t know why it does this but you should set cronjob at 60secs or so and process queue everytime it gets stuck. Occasionally you want to check and make sure it’s processing the queue.

    3) Yeah that would be ideal but this plugin has a few other issues that need to be fixed.

    • This reply was modified 6 years, 5 months ago by kimsf.
    • This reply was modified 6 years, 5 months ago by kimsf.
    • This reply was modified 6 years, 5 months ago by kimsf.

    What I did to get past it is by using this script to add a fee in functions.php and putting “free shipping” and removing it from emails and css. If you set taxes on shipping it will be based on how states treat shipping. It’ll be correct for people normally shipping items. However many states have regulations which require you to charge tax on shipping,handling,service fees, etc under special circumstances.

    God help us if we have to pay sales tax in every state. There’s only this plugin and overpriced Avatax.

    
    /**
    *  Tax Shipping Fee On Orders
    */
    function pt_add_handling_fee() {
         global $woocommerce;
     
         if ( is_admin() && ! defined( 'DOING_AJAX' ) )
              return;
     
         $fee = 9.99;
         $title = 'Flat Shipping Fee';
     
         $woocommerce->cart->add_fee( $title, $fee, TRUE, 'standard' );
    }
     
    // Action -> Add custom handling fee to an order
    add_action( 'woocommerce_cart_calculate_fees', 'pt_add_handling_fee' );
    • This reply was modified 6 years, 6 months ago by kimsf.

    Yes it still works. It really helps cut time on woocommerce when a customer is paying. Woocommerce seems to not redirect a customer to thank you page until the email is sent unless it’s queued using this plugin. Plus if the email fails to send you can always resend it using this by moving the failed emails to the queue folder.

    Thread Starter kimsf

    (@kimsf)

    Hmm then I’ll disable plugins or run vanilla woocommerce and see if the issue is still there.

    I’ve also updated the code to avoid jquery error and other issues:

    <script src="/wp-includes/js/jquery/jquery.js"></script>
    <script>var x = document.getElementById("customer_details");
    x.addEventListener("input", RemoveBillEmailSpace, true);
    function RemoveBillEmailSpace() { 
        document.getElementById("billing_email").value = document.getElementById("billing_email").value.replace(/ /, '');
    }</script>
    Thread Starter kimsf

    (@kimsf)

    How I replicate it is by putting in an e-mail address with spaces during checkout, filling out all the other fields, then entering in a test credit card, and then trying to check out. Stripe in the log shows 400 ERR and when I click it to get details at the bottom of it shows this:

    Response body

    "error": {
        "type": "invalid_request_error",
        "message": "Invalid email address: [email protected] ",
        "param": "owner[email]"
      }

    Now I do have plugins such as storefront powerpack and checkout field editor that could possibly remove validation of the field I dunno. Also apparently it’s possible to check out without the “@” in the email. It appears the field accepts anything but Stripe won’t and thus returns an error.

    It also appears that this stripe plugin will try to charge the card before checking if any of the fields on checkout are set correctly. So for example if the address field is required but I enter in nothing and then try to charge a credit card the plugin will go ahead and try to charge it but then after doing that run validation of the fields and deny the charge.

    • This reply was modified 6 years, 8 months ago by kimsf.
    • This reply was modified 6 years, 8 months ago by kimsf.
    Thread Starter kimsf

    (@kimsf)

    Credit Card of course.

    Also I figured out that the plugin doesn’t stop an email has a space in the middle of it which will also get the charge denied by Stripe.

    Here’s code that fixes that which is better than the code I first posted.

    <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
    
    <script>var x = document.getElementById("customer_details");
    x.addEventListener("blur", RemoveBillEmailSpace, true);
    function RemoveBillEmailSpace() { 
        document.getElementById("billing_email").value = document.getElementById("billing_email").value.replace(/ /, '');
    $('#billing_email').trigger("change");
    }</script>
    • This reply was modified 6 years, 8 months ago by kimsf.
    Thread Starter kimsf

    (@kimsf)

    this plugin and Stripe of course. Woocommerce allows a space at the end of email addresses but stripe doesn’t.

Viewing 15 replies - 1 through 15 (of 146 total)