Jump to content

Cart and login not working


Recommended Posts

Hi, I cant add products to the cart after upgrade to latest prestashop release.

I get this message in firebug

----------------------------------------------

TypeError: cartBlockOffset is null
  ...lockOffset.right = $(window).innerWidth() - cartBlockOffset.left - cartBlock.wid...

----------------------------------------------

and this after activating _ps_mode_dev

----------------------------------------------

 

Impossible to add the product to the cart.

textStatus: 'parsererror'
errorThrown: 'SyntaxError: JSON.parse: unexpected character'
responseText:
<br />
<b>Strict Standards</b>:  Declaration of Dispatcher::loadRoutes() should be compatible with DispatcherCore::loadRoutes($id_shop = NULL) in <b>C:\xampp\htdocs\html\smartfan-ps\override\classes\Dispatcher.php</b> on line <b>16</b><br />
{

"products": [

    {

        "id":            8,

        "link":          "http://localhost/html/smartfan-ps/sv/home/8-modell-sf-101.html",

        "quantity":      12,

        "priceByLine":   "15 480,00 kr",

        "name":          "Kaminfläkt S...",

        "price":         "15 480,00 kr",

        "price_float":   "12384",

        "idCombination": 0,

        "idAddressDelivery": 0,

        "is_gift" : 0,

        "hasAttributes": false,

        "hasCustomizedDatas": false,

        "customizedDatas":[

                ]

    },    {

        "id":            9,

        "link":          "http://localhost/html/smartfan-ps/sv/home/9-modell-sf-201.html",

        "quantity":      1,

        "priceByLine":   "1 590,00 kr",

        "name":          "Kaminfläkt S...",

        "price":         "1 590,00 kr",

        "price_float":   "1272",

        "idCombination": 0,

        "idAddressDelivery": 0,

        "is_gift" : 0,

        "hasAttributes": false,

        "hasCustomizedDatas": false,

        "customizedDatas":[

                ]

    },    {

        "id":            11,

        "link":          "http://localhost/html/smartfan-ps/sv/home/11-modell-sf-101-term.html",

        "quantity":      3,

        "priceByLine":   "4 320,00 kr",

        "name":          "Kaminfläkt S...",

        "price":         "4 320,00 kr",

        "price_float":   "3456",

        "idCombination": 0,

        "idAddressDelivery": 0,

        "is_gift" : 0,

        "hasAttributes": false,

        "hasCustomizedDatas": false,

        "customizedDatas":[

                ]

    }],

"discounts": [

],

"shippingCost": "0,00 kr",

"shippingCostFloat": "0",

"wrappingCost": "0,00 kr",

"nbTotalProducts": "16",

"total": "21 390,00 kr",

"productTotal": "21 390,00 kr",

"hasError" : false

}

Link to comment
Share on other sites

And now I get

 

Notice: Undefined index: DispatcherCore in /home/xxxx/public_html/classes/Autoload.php on line 113

Warning: require(/home/xxxxx/public_html): failed to open stream: Success in /home/xxxx/public_html/classes/Autoload.php on line 113

Fatal error: require(): Failed opening required '/home/xxxxx/public_html/' (include_path='.:/opt/alt/php54/usr/share/pear:/opt/alt/php54/usr/share/php') in /home/xxxxx/public_html/classes/Autoload.php on line 113

 

Please advice

Link to comment
Share on other sites

About the first error:

It seems there is an override used in

C:\xampp\htdocs\html\smartfan-ps\override\classes\Dispatcher.php

Which maybe has some function calls which aren't fully compatible with the latest declarations.

Maybe try to rename the above file to

C:\xampp\htdocs\html\smartfan-ps\override\classes\Dispatcher_OLD.php

For a moment and see if that solves it. (Not sure what the change in the overriding Dispatcher.php was, and it ignoring this creates other problems. Are you using a custom theme? Maybe check if there's a version for the new PrestaShop available, which may solve the problem really.

 

My 2 cents,

pascal

  • Like 1
Link to comment
Share on other sites

Please at least put your code within a "Code" block.

I wouldn't expect anyone to read my post if I were you

Hi, I cant add products to the cart after upgrade to latest prestashop release.

I get this message in firebug

----------------------------------------------

TypeError: cartBlockOffset is null
  ...lockOffset.right = $(window).innerWidth() - cartBlockOffset.left - cartBlock.wid...

----------------------------------------------

and this after activating _ps_mode_dev

----------------------------------------------

 

Impossible to add the product to the cart.

textStatus: 'parsererror'
errorThrown: 'SyntaxError: JSON.parse: unexpected character'
responseText:
<br />
<b>Strict Standards</b>:  Declaration of Dispatcher::loadRoutes() should be compatible with DispatcherCore::loadRoutes($id_shop = NULL) in <b>C:\xampp\htdocs\html\smartfan-ps\override\classes\Dispatcher.php</b> on line <b>16</b><br />
{

"products": [

    {

        "id":            8,

        "link":          "http://localhost/html/smartfan-ps/sv/home/8-modell-sf-101.html",

        "quantity":      12,

        "priceByLine":   "15 480,00 kr",

        "name":          "Kaminfläkt S...",

        "price":         "15 480,00 kr",

        "price_float":   "12384",

        "idCombination": 0,

        "idAddressDelivery": 0,

        "is_gift" : 0,

        "hasAttributes": false,

        "hasCustomizedDatas": false,

        "customizedDatas":[

                ]

    },    {

        "id":            9,

        "link":          "http://localhost/html/smartfan-ps/sv/home/9-modell-sf-201.html",

        "quantity":      1,

        "priceByLine":   "1 590,00 kr",

        "name":          "Kaminfläkt S...",

        "price":         "1 590,00 kr",

        "price_float":   "1272",

        "idCombination": 0,

        "idAddressDelivery": 0,

        "is_gift" : 0,

        "hasAttributes": false,

        "hasCustomizedDatas": false,

        "customizedDatas":[

                ]

    },    {

        "id":            11,

        "link":          "http://localhost/html/smartfan-ps/sv/home/11-modell-sf-101-term.html",

        "quantity":      3,

        "priceByLine":   "4 320,00 kr",

        "name":          "Kaminfläkt S...",

        "price":         "4 320,00 kr",

        "price_float":   "3456",

        "idCombination": 0,

        "idAddressDelivery": 0,

        "is_gift" : 0,

        "hasAttributes": false,

        "hasCustomizedDatas": false,

        "customizedDatas":[

                ]

    }],

"discounts": [

],

"shippingCost": "0,00 kr",

"shippingCostFloat": "0",

"wrappingCost": "0,00 kr",

"nbTotalProducts": "16",

"total": "21 390,00 kr",

"productTotal": "21 390,00 kr",

"hasError" : false

}

Link to comment
Share on other sites

×
×
  • Create New...