Jump to content

Invalid security token ERROR messages


mattsp

Recommended Posts

Hi,

I wondered if anyone can help.  I'm getting Invalid security token error messages when trying to do certain tasks within the Back Office.

 

6fxi02.jpg

For example when trying to disable a language, clicking on the green ticket get this error:

 

ne6h4x.jpg

 

Also when clicking on Preferences/Themes, rather then the Theme Page load up I just get a white page with the text "Select a theme for shop My shop" so I'm not able to change the theme, or specifically change the logo which is what I'm trying to do.

 

Can anyone advise?  Am thinking it's something to do with tokens, as the page URL for the themes page has token in it index.php?controller=AdminThemes&token=f60138e5ed7b2df3e300dffd4394f4c9

 

I did change the URL of the site, would appreciate any suggestions on how to fix this?

Thanks

Matt

 

 

Link to comment
Share on other sites

No fix but a quick and dirty solution: Change the address from e.g. "...adminCmsContent&addcms&id_cms_category=1&token=..."

to

"...adminCmsContent&addcms&id_cms_category=1&token=..."

 

The ampersand (&) is displayed as html encoded "&" Which of course is interpreted wrongly...

  • Like 2
Link to comment
Share on other sites

I am new to Prestshop and I have tried a few things but still get the error. 

 

I got to CMS and try to ADD a new category in the section:  Pages in category "Home" - and I get the Invalid Security Token. 

 

This the URL:  http://www.bytheolive.com/psadmin/index.php?controller=AdminCmsContent&addcms&id_cms_category=1&token=676e795c27......

 

Can anyone help me please?!

Link to comment
Share on other sites

I am new to Prestshop and I have tried a few things but still get the error. 

 

I got to CMS and try to ADD a new category in the section:  Pages in category "Home" - and I get the Invalid Security Token. 

 

This the URL:  http://www.bytheolive.com/psadmin/index.php?controller=AdminCmsContent&addcms&id_cms_category=1&token=676e795c27......

 

Can anyone help me please?!

 

You have to change 2 files on your FTP ... Presta installation

According following instructions

https://github.com/PrestaShop/PrestaShop/commit/84eaa4f9cbb773dc481f3cf84f63db1a7d253827

 

It means change 

controllers/admin/AdminCmsCategoriesController.php

and 

controllers/admin/AdminCmsController.php

  • Like 1
Link to comment
Share on other sites

  • 3 weeks later...
  • 2 weeks later...
  • 1 month later...

You have to change 2 files on your FTP ... Presta installation

According following instructions

https://github.com/PrestaShop/PrestaShop/commit/84eaa4f9cbb773dc481f3cf84f63db1a7d253827

 

It means change 

controllers/admin/AdminCmsCategoriesController.php

and 

controllers/admin/AdminCmsController.php

Hell I too am having the same problem with adding a CMS page to my prestashop site and I get the invalid security token error message and I see the code on the page at the above web address, however when I go to this page to find out how to correct this problem all I see is a code, there are no instructions on how and what to do or what to change from what to what. I am new to prestashop 1.6 as I know a lot of other people are and the  instruction above is not of any help at all to someone who does not know anything about this type of code, I don't even know where to find the code at, no one even mentioned that either. Can some one please break the instructions down in simpler form, so that I and others can understand what you're saying. Thanks, Please help as soon as possible!    

Link to comment
Share on other sites

  • 1 month later...

Thanks marcofalco for the solution.

 

pb4sc  

 

Dean

   The stuff in the red is the line you need to edit.   The Green one is what it should be.   Open the files in an editor.  Get to the line of code.   Change it to what it is in the green.   Most involve removing amp;  

Make sure you have copies of both files just in case.

 

You need to find the individual file, and the path is controllers/admin/AdminCmsCategoriesController.php  and controllers/admin/AdminCmsController.php   Open your files, with FileZilla or another ftp.   

Edited by pb4sc (see edit history)
Link to comment
Share on other sites

  • 2 weeks later...

I am still getting this error! So frustrating!!!!

 

PrestaShop version 1.6.0.8

Shop URL http://royaltrappings.com/

Current theme in use default-bootstrap

 

I have done the "fix" but it still gives me error when I hit add new item in catalog.

 

http://royaltrappings.com/admin3273/index.php?controller=AdminProducts&addproduct&token=5a3b989f48fdabb8d683a34dcbfb6b81

 

 

I even tried to remove a menu item "suppliers" and got the same Invalid Security Token error.

 

http://royaltrappings.com/admin3273/index.php?controller=AdminTabs&detailstab&id_tab=27&statustab&token=dfec9860fa1ff5a54d61f0a256a6b5dc

 

What am I doing wrong?

Thank you! Any help would be greatly appreciated.

 

Link to comment
Share on other sites

×
×
  • Create New...