Jump to content

Invalid Token Message


Recommended Posts

One of the repeating times this message occurs seems to be after I have from the Back Office emptied the cart of a browser. How should I reproduce that error for you?

 

Are there specific steps I can take as a potential customer (in the Front Office) that would give me this error? I just tried again, and continue to have no trouble adding products to the cart.

 

-Mike

Link to comment
Share on other sites

  • 2 months later...

Hi,

i have the same problem and i don't know hao to solve it.

WHen the costumer is not logged, there's no problem, the product is going in the cart.

But, when the costumer is logged, and click on "add to cart" a new page appears whit the error 01.token invalid

 

I tried to empty cache of my navigator

i tried to update paypal module

 

what can i do for that?

Thanks (and sorry for my bad english)

Link to comment
Share on other sites

hi, yes it's enable.

You have to know that i use the module ebsupercache too.

 

Can you please disable "Increase Front Office Security," ensure that you have Force Compile set to Yes and Cache set to No under Preferences > Performance and then let me know if that works better for you?

 

There is a code fix I can suggest for this, but I want to confirm that this is the root of your issue first.

 

-Mike

Link to comment
Share on other sites

Hi corbeille,

This appears to be an issue with a missing security token. In your modules/blocklayered/blocklayered.php file, please locate the following line:

$smarty->assign('products_per_page', (int)Configuration::get('PS_PRODUCTS_PER_PAGE'));

And just after that, add this:

 

$smarty->assign('static_token', Tools::getToken(false));

 

That should allow you to reactivate the Front Office Security and resolve this issue.

 

I hope this helps. Please let me know if this works for you.

 

-Mike

Link to comment
Share on other sites

Hi, i'd this error

 

Fatal error: Call to a member function assign() on a non-object in /public_html/modules/blocklayered/blocklayered.php on line 30

 

Can you please email me a copy of your blocklayered.php file to mike DOT kranzler AT prestashop DOT com? I'll take a look at it for you and try to identify where there may be an error.

 

-Mike

Link to comment
Share on other sites

bad news!

in fact it doesn't work...

in BO, i've this error:

 

The following module(s) couldn't be loaded:

  1. blocklayered (parse error in /modules/blocklayered/blocklayered.php)
  2. blocklayered (class missing in /modules/blocklayered/blocklayered.php)

 

and on FO:

sometimes i'm connected, sometimes not,

token invalid here again when i took a product when i'm connected

 

sorry

Link to comment
Share on other sites

×
×
  • Create New...