Mariadb错误:此MariaDB不允许使用该命令

In mariadb, when I use "load data local infile" into a php script, I get this error message:

the used command is not allowed with this MariaDB version for the query load data local infile

This is the same thing than on this thread.

I'm on CentOS 7 - Plesk Onyx and my my.cnf contains:

local-infile=1

If I use "load data infile", I can import my csv file into my MySQL table but the csv file must to be located into the directory /var/lib/mysql/my_database/

But I can't create a csv file into /var/lib/mysql/my_database/ from a php script located into /var/www/vhosts/my-website.com/httpdocs/my_script.php

if I use "load data infile", I can import my csv file into my MySQL table but the csv file must to be located into the directory /var/lib/mysql/my_database/

But I can't create a csv file into /var/lib/mysql/my_database/ from a php script located into /var/www/vhosts/my-website.com/httpdocs/my_script.php it doesn't work!

What is the solution?

See PHP's open_basedir for restrictions on PHP writing: http://php.net/manual/en/ini.core.php