• Resolved lordjim2014

    (@lordjim2014)


    Hi – I tried to install your plugin and keep getting this message even after a few uninstall/re-installs

    Error Message

    Fatal Error: syntax error, unexpected ‘[‘ in /home/21/27/3102721/web/wp-content/plugins/canada-post-shipping-for-woocommerce/canadapost.php on line 512

    Description

    The Canada Post Shipping For WooCommerce By CanShip plugin code created an error that caused PHP execution to fail.

    This type error is called a “syntax error.” A syntax error means that the format of the code is invalid. Examples of syntax errors: a missing semicolon after a line of code, having mismatched parentheses, forgetting to put a dollar sign ($) in front of a variable’s name, and forgetting an operator — such as a plus sign (+) — between two variables. There are many other possible causes of syntax errors, the preceding are just a few examples.

    Solutions
    ◦Invalid code modifications can cause this problem. If you have made any modifications to the plugin, remove them and try to load the site again.
    ◦It is possible that this plugin’s code is out of date and that an upgrade is available. Check with the plugin’s author to see if an upgrade is available.
    ◦There may be a conflict with another plugin running on the site. Try upgrading the other plugins on the site. A plugin conflict can be ruled out by deactivating all the other active plugins on the site and checking to see if the error still occurs.
    ◦The Canada Post Shipping For WooCommerce By CanShip plugin may not have been fully uploaded. Uploading the plugin again could fix the issue. Important: If you do this, you will lose any modifications made to the plugin.

    Error Source Details

    Type
    Plugin

    Name
    Canada Post Shipping For WooCommerce By CanShip

    Version
    1.0

    Author
    CanShip

    Path
    /home/21/27/3102721/web/wp-content/plugins/canada-post-shipping-for-woocommerce

    File
    canadapost.php

    Other Software Details

    WordPress Version
    4.0.1

    PHP Version
    5.3.3-7.4+hw2

    Full Error Details

    Type
    Parse Error (E_PARSE)

    Message
    syntax error, unexpected ‘[‘

    File
    /home/21/27/3102721/web/wp-content/plugins/canada-post-shipping-for-woocommerce/canadapost.php

    Line
    512

    Type Description
    This type of error indicates that the PHP code is invalid and is typically referred to as a syntax error. It basically means that the code was written incorrectly and is preventing PHP from being able to read the code properly.

    https://ww.wp.xz.cn/plugins/canada-post-shipping-for-woocommerce/

Viewing 6 replies - 1 through 6 (of 6 total)
  • Thanks for downloading the plugin and giving it a try.

    I’m busy for most of the day at work but I can take a look at the error this evening and see what I can find to help you out.

    Hi LordJim2014.

    I’ve found the issue and put a fix up. Can you reinstall the plugin and let me know if you still have any trouble?

    I’ll mark this as resolved unless I hear otherwise.

    Thanks 🙂

    Thread Starter lordjim2014

    (@lordjim2014)

    Hey thanks for getting on that so quickly! So it installed, found it and the instructions just fine, but now my snag is that it won’t populate as an option in the cart/checkout… I’ve converted the woocommerce interface and product dimensions/weight measurements to be in mm and g as I had thought that may be the problem but not so. I’ve tried disabling the other shipping methods and still nada – I can’t get the option to show up as a shipping class in my edit product section so I’m kinda stumped.

    Please don’t feel like I’m complaining, I think it’s a terrific idea, and it’s 99% there and I hope to make it work, maybe I’M just missing something. Thanks again for your support!

    Hey. No problem. The plugin is new so working out the kinks is par for the course.

    Currently the plugin won’t show up as a shipping class. If *all* of the items in the cart fit within the sizes and weights of the tables shown by the plugin then the shipping option will show on the checkout screen.

    If there is one or more items in the cart that don’t fit within the weight and size restriction the option won’t be available during checkout.

    What is a specific size and weight of one of your items?

    Thread Starter lordjim2014

    (@lordjim2014)

    http://www.imagesoffascination.ca

    I’ve made product # B028 65mm x 200mm x .03mm and it weighs 3 grams, its the only thing in the cart (test, all the other products are in inches *groan*) – but that’s all good – I’d change it up if it works & just leave the “inches” in the product description. Thanks again!

    Cool website. We actually live close. I’m up in the Okanagan. 🙂

    Your dimensions and weight should be working. To confirm your fields are filled out like mine in the linked image below?

    http://canadianshippingcalculator.com/wp-content/uploads/2014/12/Screen-Shot-2014-12-04-at-12.24.28-PM.png

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘I've hit a dead end.’ is closed to new replies.