I switched to the uncompressed 1.12.4 and here is the full console log
jquery.checkout_one.min.js?1598622382:5 setFormSubmitButton, payment-module: null
jquery.checkout_one.min.js?1598622382:5 Showing "confirm"
jquery.checkout_one.min.js?1598622382:5 Setting orderConfirmed (0), submitter (null)
jquery.checkout_one.min.js?1598622382:5 jQuery version: 1.12.4
jquery.checkout_one.min.js?1598622382:5 saveCustomerInfo, starts ...
index.php?main_page=checkout_one&zenid=eh8g36jjbg0uhqlfqplgu0ham6:58 {cache: false, type: "POST", traditional: true, dataType: "json", timeout: 5000,##…}
jquery.checkout_one.min.js?1598622382:5 Uncaught TypeError: Cannot read property 'length' of null
at Object.<anonymous> (jquery.checkout_one.min.js?1598622382:5)
at fire (jscript__jquery.min.js:3232)
at Object.fireWith [as resolveWith] (jscript__jquery.min.js:3362)
at Object.deferred.<computed> [as resolve] (jscript__jquery.min.js:3461)
at Object.success (index.php?main_page=checkout_one&zenid=eh8g36jjbg0uhqlfqplgu0ham6:66)
at fire (jscript__jquery.min.js:3232)
at Object.fireWith [as resolveWith] (jscript__jquery.min.js:3362)
at done (jscript__jquery.min.js:9840)
at XMLHttpRequest.callback (jscript__jquery.min.js:10311)
FYI, I get the same error (Uncaught TypeError: Cannot read property 'length' of null) when using 3.6.0
@jeking,
instead of using non-minified files for only jQuery itself, I think what lat9 would find most useful is using the OPC's non-minified files.
Switch it in Admin -> Configuration -> OPC -> Load Minified Script Files
.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole
Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.
Oh sorry, I misunderstood. Do that I get this:
jquery.checkout_one.js?1598622382:972
Uncaught TypeError: Cannot read property 'length' of null
at Object.<anonymous> (jquery.checkout_one.js?1598622382:972)
at n (jscript__jquery.min.js:2)
at Object.fireWith (jscript__jquery.min.js:2)
at Object.fire [as resolve] (jscript__jquery.min.js:2)
at Object.success (index.php?main_page=checkout_one:66)
at n (jscript__jquery.min.js:2)
at Object.fireWith [as resolveWith] (jscript__jquery.min.js:2)
at w (jscript__jquery.min.js:4)
at XMLHttpRequest.d (jscript__jquery.min.js:4)
Jim, there have been numerous changes/corrections to the jquery.checkout_one.js in the time since OPC v2.3.4 was released last August. Might I suggest that it's time to upgrade to v2.3.8?
Hi Please help
This is my first post so please forgive me if I don't give enough information.
I have installed OPC on v1.5.7c and when I run the store in non SSL mode it works fine. As soon as I enable SSL then I get a WHOOPS! YOUR SESSION HAS EXPIRED. page when I click check out as a guest. Part of the log file is below ( it wouldnt let me post the fuull log). Has anyone any ideas how to resolve this. thank you.
2021-05-10 16:31:36 checkout_one_observer: checkout_one redirect 1a: array (
'main_page' => 'checkout_shipping',
)
array (
'securityToken' => '67690581ed153967dcea3f1104ce6db5',
'customers_host_address' => 'broadband.bt.com',
'SSL_SESSION_ID' => NULL,
'opc' =>
OnePageCheckout::__set_state(array(
'isGuestCheckoutEnabled' => true,
'registeredAccounts' => true,
'guestIsActive' => false,
'isEnabled' => true,
'tempAddressValues' => NULL,
'guestCustomerInfo' => NULL,
'guestCustomerId' => 3,
'tempBilltoAddressBookId' => 3,
'tempSendtoAddressBookId' => 4,
'dbStringType' => 'stringIgnoreNull',
'paypalAddressOverride' => NULL,
'paypalTotalValue' => NULL,
'paypalTotalValueChanged' => NULL,
'paypalNoShipping' => NULL,
'customerInfoOk' => NULL,
'billtoTempAddrOk' => NULL,
'sendtoTempAddrOk' => NULL,
'isVirtualOrder' => NULL,
'billtoAddressChangeable' => NULL,
'sendtoAddressChangeable' => NULL,
'observerAliases' =>
array (
'NOTIFIY_ORDER_CART_SUBTOTAL_CALCULATE' => 'NOTIFY_ORDER_CART_SUBTOTAL_CALCULATE',
),
)),
'cartID' => '',
'cart' =>
shoppingCart::__set_state(array(
'contents' =>
array (
'3:4f4ef1da0c407f06362a1c6ae9652e3b' =>
array (
'qty' => 1.0,
'attributes' =>
array (
1 => 1,
2 => 4,
),
),
),
'total' => 5.0,
'weight' => 290.0,
'cartID' => '88750',
'content_type' => false,
'free_shipping_item' => 0,
'free_shipping_weight' => 0,
'free_shipping_price' => 0.0,
'download_count' => 0,
'total_before_discounts' => 5.0,
'display_debug_messages' => false,
'flag_duplicate_msgs_set' => false,
'flag_duplicate_quantity_msgs_set' =>
array (
),
'observerAliases' =>
array (
'NOTIFIY_ORDER_CART_SUBTOTAL_CALCULATE' => 'NOTIFY_ORDER_CART_SUBTOTAL_CALCULATE',
),
)),
'check_valid_prod' => true,
'navigation' =>
navigationHistory::__set_state(array(
'path' =>
array (
0 =>
array (
'page' => 'index',
'mode' => 'SSL',
'get' =>
array (
'cPath' => '1_3',
),
'post' =>
array (
),
),
1 =>
array (
'page' => 'product_info',
'mode' => 'SSL',
'get' =>
array (
'cPath' => '1_3',
'products_id' => '3',
'number_of_uploads' => '0',
'action' => 'add_product',
),
'post' =>
array (
),
),
2 =>
array (
'page' => 'shopping_cart',
'mode' => 'SSL',
'get' =>
array (
),
'post' =>
array (
),
),
3 =>
array (
'page' => 'checkout_shipping',
'mode' => 'SSL',
'get' =>
array (
),
'post' =>
array (
),
),
),
'snapshot' =>
array (
'page' => 'product_info',
'mode' => 'SSL',
'get' =>
array (
'cPath' => '1_3',
'products_id' => '3',
),
'post' =>
array (
),
),
'observerAliases' =>
array (
'NOTIFIY_ORDER_CART_SUBTOTAL_CALCULATE' => 'NOTIFY_ORDER_CART_SUBTOTAL_CALCULATE',
),
)),
'language' => 'english',
'languages_id' => 1,
'languages_code' => 'en',
'layoutType' => 'legacy',
'currency' => 'GBP',
'today_is' => '2021-05-10',
'updateExpirations' => true,
'antispam_fieldname' => '9WG9nBpwNV',
'session_counter' => true,
'customers_ip_address' => '2a00:23c6:3b94:8700:b4a8:7c5:210f:f68',
'new_products_id_in_cart' => '3:4f4ef1da0c407f06362a1c6ae9652e3b',
'valid_to_checkout' => true,
'cart_errors' => '',
)
2021-05-10 16:31:37 checkout_one: CHECKOUT_ONE_ENTRY, version (2.3.8 (2021-04-17)), Zen Cart version (1.5.7c), template (winchester_responsive)
2021-05-10 16:31:37 OnePageCheckout: startGuestOnePageCheckout, exit: sendto: not set, billto: not setOnePageCheckout::__set_state(array(
'isGuestCheckoutEnabled' => true,
'registeredAccounts' => true,
'guestIsActive' => false,
'isEnabled' => true,
'tempAddressValues' =>
array (
'ship' =>
array (
'gender' => '',
'company' => '',
'firstname' => '',
'lastname' => '',
'street_address' => '',
'suburb' => '',
'city' => '',
'postcode' => '',
'state' => '',
'country' => 222,
'country_id' => 222,
'zone_id' => 0,
'zone_name' => '0',
'address_book_id' => 0,
'selected_country' => 222,
'country_has_zones' => false,
'state_field_label' => '',
'show_pulldown_states' => true,
'error' => false,
'error_state_input' => false,
'validated' => false,
),
'bill' =>
array (
'gender' => '',
'company' => '',
'firstname' => '',
'lastname' => '',
'street_address' => '',
'suburb' => '',
'city' => '',
'postcode' => '',
'state' => '',
'country' => 222,
'country_id' => 222,
'zone_id' => 0,
'zone_name' => '0',
'address_book_id' => 0,
'selected_country' => 222,
'country_has_zones' => false,
'state_field_label' => '',
'show_pulldown_states' => true,
'error' => false,
'error_state_input' => false,
'validated' => false,
),
),
'guestCustomerInfo' => NULL,
'guestCustomerId' => 3,
'tempBilltoAddressBookId' => 3,
'tempSendtoAddressBookId' => 4,
'dbStringType' => 'stringIgnoreNull',
'paypalAddressOverride' => NULL,
'paypalTotalValue' => NULL,
'paypalTotalValueChanged' => NULL,
'paypalNoShipping' => NULL,
'customerInfoOk' => NULL,
'billtoTempAddrOk' => NULL,
'sendtoTempAddrOk' => NULL,
'isVirtualOrder' => NULL,
'billtoAddressChangeable' => NULL,
'sendtoAddressChangeable' => NULL,
'observerAliases' =>
array (
'NOTIFIY_ORDER_CART_SUBTOTAL_CALCULATE' => 'NOTIFY_ORDER_CART_SUBTOTAL_CALCULATE',
),
))
2021-05-10 16:31:41 checkout_one: CHECKOUT_ONE_ENTRY, version (2.3.8 (2021-04-17)), Zen Cart version (1.5.7c), template (winchester_responsive)
2021-05-10 16:31:41 OnePageCheckout: startGuestOnePageCheckout, exit: sendto: not set, billto: not setOnePageCheckout::__set_state(array(
'isGuestCheckoutEnabled' => true,
'registeredAccounts' => true,
'guestIsActive' => true,
'isEnabled' => true,
'tempAddressValues' =>
array (
'ship' =>
array (
'gender' => '',
'company' => '',
'firstname' => '',
'lastname' => '',
'street_address' => '',
'suburb' => '',
'city' => '',
'postcode' => '',
'state' => '',
'country' => 222,
'country_id' => 222,
'zone_id' => 0,
'zone_name' => '0',
'address_book_id' => 0,
'selected_country' => 222,
'country_has_zones' => false,
'state_field_label' => '',
'show_pulldown_states' => true,
'error' => false,
'error_state_input' => false,
'validated' => false,
),
'bill' =>
array (
'gender' => '',
'company' => '',
'firstname' => '',
'lastname' => '',
'street_address' => '',
'suburb' => '',
'city' => '',
'postcode' => '',
'state' => '',
'country' => 222,
'country_id' => 222,
'zone_id' => 0,
'zone_name' => '0',
'address_book_id' => 0,
'selected_country' => 222,
'country_has_zones' => false,
'state_field_label' => '',
'show_pulldown_states' => true,
'error' => false,
'error_state_input' => false,
'validated' => false,
),
),
'guestCustomerInfo' =>
array (
'firstname' => '',
'lastname' => '',
'email_address' => '',
'telephone' => '',
'dob' => '',
),
'guestCustomerId' => 3,
'tempBilltoAddressBookId' => 3,
'tempSendtoAddressBookId' => 4,
'dbStringType' => 'stringIgnoreNull',
'paypalAddressOverride' => NULL,
'paypalTotalValue' => NULL,
'paypalTotalValueChanged' => NULL,
'paypalNoShipping' => NULL,
'customerInfoOk' => false,
'billtoTempAddrOk' => false,
'sendtoTempAddrOk' => false,
'isVirtualOrder' => NULL,
'billtoAddressChangeable' => NULL,
'sendtoAddressChangeable' => NULL,
'observerAliases' =>
array (
'NOTIFIY_ORDER_CART_SUBTOTAL_CALCULATE' => 'NOTIFY_ORDER_CART_SUBTOTAL_CALCULATE',
),
))
2021-05-10 16:34:20 checkout_one_observer: checkout_one redirect 1a: array (
'main_page' => 'checkout_shipping',
)
array (
'securityToken' => 'd26ea0bee3497c9a50256128f9cf44ad',
'customers_host_address' => 'broadband.bt.com',
'SSL_SESSION_ID' => NULL,
'opc' =>
OnePageCheckout::__set_state(array(
'isGuestCheckoutEnabled' => true,
'registeredAccounts' => true,
'guestIsActive' => false,
'isEnabled' => true,
'tempAddressValues' => NULL,
'guestCustomerInfo' => NULL,
'guestCustomerId' => 3,
'tempBilltoAddressBookId' => 3,
'tempSendtoAddressBookId' => 4,
'dbStringType' => 'stringIgnoreNull',
'paypalAddressOverride' => NULL,
'paypalTotalValue' => NULL,
'paypalTotalValueChanged' => NULL,
'paypalNoShipping' => NULL,
'customerInfoOk' => NULL,
'billtoTempAddrOk' => NULL,
'sendtoTempAddrOk' => NULL,
'isVirtualOrder' => NULL,
'billtoAddressChangeable' => NULL,
'sendtoAddressChangeable' => NULL,
'observerAliases' =>
array (
'NOTIFIY_ORDER_CART_SUBTOTAL_CALCULATE' => 'NOTIFY_ORDER_CART_SUBTOTAL_CALCULATE',
),
)),
'cartID' => '',
'cart' =>
shoppingCart::__set_state(array(
'contents' =>
array (
'3:4f4ef1da0c407f06362a1c6ae9652e3b' =>
array (
'qty' => 1.0,
'attributes' =>
array (
1 => 1,
2 => 4,
),
),
),
'total' => 5.0,
'weight' => 290.0,
'cartID' => '99995',
'content_type' => false,
'free_shipping_item' => 0,
'free_shipping_weight' => 0,
'free_shipping_price' => 0.0,
'download_count' => 0,
'total_before_discounts' => 5.0,
'display_debug_messages' => false,
'flag_duplicate_msgs_set' => false,
'flag_duplicate_quantity_msgs_set' =>
array (
),
'observerAliases' =>
array (
'NOTIFIY_ORDER_CART_SUBTOTAL_CALCULATE' => 'NOTIFY_ORDER_CART_SUBTOTAL_CALCULATE',
),
)),
'check_valid_prod' => true,
'navigation' =>
navigationHistory::__set_state(array(
'path' =>
array (
0 =>
array (
'page' => 'index',
'mode' => 'SSL',
'get' =>
array (
'cPath' => '1_3',
),
'post' =>
array (
),
),
1 =>
array (
'page' => 'product_info',
'mode' => 'SSL',
'get' =>
array (
'cPath' => '1_3',
'products_id' => '3',
'number_of_uploads' => '0',
'action' => 'add_product',
),
'post' =>
array (
),
),
2 =>
array (
'page' => 'shopping_cart',
'mode' => 'SSL',
'get' =>
array (
),
'post' =>
array (
),
),
3 =>
array (
'page' => 'checkout_shipping',
'mode' => 'SSL',
'get' =>
array (
),
'post' =>
array (
),
),
),
'snapshot' =>
array (
'page' => 'product_info',
'mode' => 'SSL',
'get' =>
array (
'cPath' => '1_3',
'products_id' => '3',
),
'post' =>
array (
),
),
'observerAliases' =>
array (
'NOTIFIY_ORDER_CART_SUBTOTAL_CALCULATE' => 'NOTIFY_ORDER_CART_SUBTOTAL_CALCULATE',
),
)),
'language' => 'english',
'languages_id' => 1,
'languages_code' => 'en',
'layoutType' => 'legacy',
'currency' => 'GBP',
'today_is' => '2021-05-10',
'updateExpirations' => true,
'antispam_fieldname' => 'tkcK433Uzo',
'session_counter' => true,
'customers_ip_address' => '2a00:23c6:3b94:8700:91d3:13f8:5e6f:c638',
'new_products_id_in_cart' => '3:4f4ef1da0c407f06362a1c6ae9652e3b',
'valid_to_checkout' => true,
'cart_errors' => '',
)
2021-05-10 16:34:21 checkout_one: CHECKOUT_ONE_ENTRY, version (2.3.8 (2021-04-17)), Zen Cart version (1.5.7c), template (winchester_responsive)
2021-05-10 16:34:21 OnePageCheckout: startGuestOnePageCheckout, exit: sendto: not set, billto: not setOnePageCheckout::__set_state(array(
'isGuestCheckoutEnabled' => true,
'registeredAccounts' => true,
'guestIsActive' => false,
'isEnabled' => true,
'tempAddressValues' =>
array (
'ship' =>
array (
'gender' => '',
'company' => '',
'firstname' => '',
'lastname' => '',
'street_address' => '',
'suburb' => '',
'city' => '',
'postcode' => '',
'state' => '',
'country' => 222,
'country_id' => 222,
'zone_id' => 0,
'zone_name' => '0',
'address_book_id' => 0,
'selected_country' => 222,
'country_has_zones' => false,
'state_field_label' => '',
'show_pulldown_states' => true,
'error' => false,
'error_state_input' => false,
'validated' => false,
),
'bill' =>
array (
'gender' => '',
'company' => '',
'firstname' => '',
'lastname' => '',
'street_address' => '',
'suburb' => '',
'city' => '',
'postcode' => '',
'state' => '',
'country' => 222,
'country_id' => 222,
'zone_id' => 0,
'zone_name' => '0',
'address_book_id' => 0,
'selected_country' => 222,
'country_has_zones' => false,
'state_field_label' => '',
'show_pulldown_states' => true,
'error' => false,
'error_state_input' => false,
'validated' => false,
),
),
'guestCustomerInfo' => NULL,
'guestCustomerId' => 3,
'tempBilltoAddressBookId' => 3,
'tempSendtoAddressBookId' => 4,
'dbStringType' => 'stringIgnoreNull',
'paypalAddressOverride' => NULL,
'paypalTotalValue' => NULL,
'paypalTotalValueChanged' => NULL,
'paypalNoShipping' => NULL,
'customerInfoOk' => NULL,
'billtoTempAddrOk' => NULL,
'sendtoTempAddrOk' => NULL,
'isVirtualOrder' => NULL,
'billtoAddressChangeable' => NULL,
'sendtoAddressChangeable' => NULL,
'observerAliases' =>
array (
'NOTIFIY_ORDER_CART_SUBTOTAL_CALCULATE' => 'NOTIFY_ORDER_CART_SUBTOTAL_CALCULATE',
),
))
2021-05-10 16:34:32 checkout_one: CHECKOUT_ONE_ENTRY, version (2.3.8 (2021-04-17)), Zen Cart version (1.5.7c), template (winchester_responsive)
2021-05-10 16:34:32 OnePageCheckout: startGuestOnePageCheckout, exit: sendto: not set, billto: not setOnePageCheckout::__set_state(array(
'isGuestCheckoutEnabled' => true,
'registeredAccounts' => true,
'guestIsActive' => true,
'isEnabled' => true,
'tempAddressValues' =>
array (
'ship' =>
array (
'gender' => '',
'company' => '',
'firstname' => '',
'lastname' => '',
'street_address' => '',
'suburb' => '',
'city' => '',
'postcode' => '',
'state' => '',
'country' => 222,
'country_id' => 222,
'zone_id' => 0,
'zone_name' => '0',
'address_book_id' => 0,
'selected_country' => 222,
'country_has_zones' => false,
'state_field_label' => '',
'show_pulldown_states' => true,
'error' => false,
'error_state_input' => false,
'validated' => false,
),
'bill' =>
array (
'gender' => '',
'company' => '',
'firstname' => '',
'lastname' => '',
'street_address' => '',
'suburb' => '',
'city' => '',
'postcode' => '',
'state' => '',
'country' => 222,
'country_id' => 222,
'zone_id' => 0,
'zone_name' => '0',
'address_book_id' => 0,
'selected_country' => 222,
'country_has_zones' => false,
'state_field_label' => '',
'show_pulldown_states' => true,
'error' => false,
'error_state_input' => false,
'validated' => false,
),
),
'guestCustomerInfo' =>
array (
'firstname' => '',
'lastname' => '',
'email_address' => '',
'telephone' => '',
'dob' => '',
),
'guestCustomerId' => 3,
'tempBilltoAddressBookId' => 3,
'tempSendtoAddressBookId' => 4,
'dbStringType' => 'stringIgnoreNull',
'paypalAddressOverride' => NULL,
'paypalTotalValue' => NULL,
'paypalTotalValueChanged' => NULL,
'paypalNoShipping' => NULL,
'customerInfoOk' => false,
'billtoTempAddrOk' => false,
'sendtoTempAddrOk' => false,
'isVirtualOrder' => NULL,
'billtoAddressChangeable' => NULL,
'sendtoAddressChangeable' => NULL,
'observerAliases' =>
array (
'NOTIFIY_ORDER_CART_SUBTOTAL_CALCULATE' => 'NOTIFY_ORDER_CART_SUBTOTAL_CALCULATE',
),
))
2021-05-10 16:41:54 checkout_one_observer: checkout_one redirect 1a: array (
'main_page' => 'checkout_shipping',
)
array (
'securityToken' => '8af9952d712f141b5d363cf765bafe42',
'customers_host_address' => 'broadband.bt.com',
'SSL_SESSION_ID' => NULL,
'opc' =>
OnePageCheckout::__set_state(array(
'isGuestCheckoutEnabled' => true,
'registeredAccounts' => true,
'guestIsActive' => false,
'isEnabled' => true,
'tempAddressValues' => NULL,
'guestCustomerInfo' => NULL,
'guestCustomerId' => 3,
'tempBilltoAddressBookId' => 3,
'tempSendtoAddressBookId' => 4,
'dbStringType' => 'stringIgnoreNull',
'paypalAddressOverride' => NULL,
'paypalTotalValue' => NULL,
'paypalTotalValueChanged' => NULL,
'paypalNoShipping' => NULL,
'customerInfoOk' => NULL,
'billtoTempAddrOk' => NULL,
'sendtoTempAddrOk' => NULL,
'isVirtualOrder' => NULL,
'billtoAddressChangeable' => NULL,
'sendtoAddressChangeable' => NULL,
'observerAliases' =>
array (
'NOTIFIY_ORDER_CART_SUBTOTAL_CALCULATE' => 'NOTIFY_ORDER_CART_SUBTOTAL_CALCULATE',
),
)),
'cartID' => '',
'cart' =>
shoppingCart::__set_state(array(
'contents' =>
array (
'5:2f1d77905d81c46c3e7d0db87e48588f' =>
array (
'qty' => 1.0,
'attributes' =>
array (
1 => 1,
2 => 4,
),
),
),
'total' => 4.0,
@Lintong, welcome to the Zen Cart forums! Those OPC log files, as you found, can get very large ... to large for posting on the forums directly.
When you 'enabled' SSL in your site's /includes/configure.php and the /YOUR_ADMIN/includes/configure.php, what did you change? The recommended settings (for the storefront) are (pretending that your site is example.com):
define('HTTP_SERVER', 'https://example.com');
define('HTTPS_SERVER', 'https://example.com');
define('ENABLE_SSL', 'true');
Is that different from what you've used? Note, too, that Zen Cart automatically forces the /includes/configure.php file to be read-only, so if you think you've made changes, check the file again just to be sure.
Hi,
Thank you for replying.
The settings are as you have said. I reinstalled with ssl so the settings would be correct.
Bookmarks