I set it to the .htaccess
file.
Add the following code to .htaccess
.
<IfModule mod_headers.c>
Header add Access-Control-Allow-Origin "*"
Header add Access-Control-Allow-Headers"*"
Header add Access-Control-Allow-Methods "OPTIONS, GET, POST, PUT, DELETE"
Header add Access-Control-Max-Age 86400
</IfModule>
This file is located in the public folder.If it does not exist, refer to the image below.
Rename .htaccess.example
to .htaccess
.
© 2024 OneMinuteCode. All rights reserved.