ociwordpress-pro

Enable CORS

Follow these steps:

  • Edit the NGINX configuration file at /opt/bitnami/apps/wordpress/conf/nginx-app.conf file and add the following lines to it:

    location ~* .(eot|otf|svg|ttf|woff|woff2)$ {
      add_header Access-Control-Allow-Origin *;
    }
    
  • Edit the /opt/bitnami/nginx/conf/mime.types file and add the following lines to it within the [type] block:

    application/vnd.ms-fontobject eot;
    application/x-font-opentype otf;
    image/svg+xml svg;
    application/x-font-ttf ttf;
    application/font-woff woff;
    application/font-woff2 woff2;
    
  • Restart the NGINX server:

    $ sudo /opt/bitnami/ctlscript.sh restart nginx
    
Last modification March 19, 2019