Answer the question
In order to leave comments, you need to log in
How to defeat error in the admin panel of Opencart?
There is a subdomain. It has a site on OpenCart.
sub.example.com - shop
sub.example.com/admin -
admin panel googled .htaccess
Header always set Access-Control-Allow-Origin "*"
Header always set Access-Control-Allow-Methods "POST, GET, OPTIONS, DELETE, PUT"
Header always set Access-Control-Max-Age "1000"
Header always set Access-Control-Allow-Headers "x-requested-with, Content-Type, origin, authorization, accept, client-security-token"
# Added a rewrite to respond with a 200 SUCCESS on every OPTIONS request.
RewriteEngine On
RewriteCond %{REQUEST_METHOD} OPTIONS
RewriteRule ^(.*)$ $1 [R=200,L]
SyntaxError: JSON.parse: unexpected character at line 1 column 1 of the JSON data
OK
Запрос из постороннего источника заблокирован: Политика одного источника запрещает чтение удаленного ресурса на http://sub.example.com/admin/index.php?route=dashboard/chart/chart&token=twQohHe6yJAAI4CqH9rBJdxX42RYGCCo&range=month. (Причина: отсутствует заголовок CORS 'Access-Control-Allow-Origin').
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question