Jump to content

The CSRF token is invalid. how can i change where pHP is found?


hepkat63

Recommended Posts

i have a problem when i try to add a new product, 

i get the error: The CSRF token is invalid. Please try to resubmit the form.

 

I have the same issue, however I'm not able to 'downgrade' php versions as my other clients use the later version.  I downloaded the latest prestashop hoping it would use 7.4 - but no

Is there any way i can point prestashop to look for php.ini somewhere else?  I.e  currently , my server stores this at /etc/php.ini  however I have virtualmin and can use downgraded versions of php back to 5.4 if I have too - but need to know whereabouts in prestashop it's configuration files look for the php installation.  Can anyone help please?

Link to comment
Share on other sites

  • 2 weeks later...
  • 5 months later...

If this  not work, edit the file /src/Core/Feature/TokenInUrls.php

change the isDisabled function whith:

public static function isDisabled()
    {
        //return getenv(self::ENV_VAR) === self::DISABLED;
        return false;
    }

greetings

Link to comment
Share on other sites

  • 11 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...