Missing icons from Admin Panel

Hello.

What could have happend with the admin panel icons?

They are missing.

I have overwritten the admin plugin, but not working. I have two subdomains with two grav pages, in the first all work fine and in second this happens.

Any help?

I’ve discovered the following with Chrome Inspector:

jv_gestion:1 Access to font at ‘https://prueba.juanvillen.es/user/plugins/admin/themes/grav/fonts/forkawesome-webfont.woff2?v=1.1.5’ from origin ‘http://prueba.juanvillen.es’ has been blocked by CORS policy: No ‘Access-Control-Allow-Origin’ header is present on the requested resource.

After a long search, this afternoon, I’ve managed to solve this issue:

In the .htaccess of your site, you have to add this:

FilesMatch "\.(ttf|otf|eot|woff|woff2)$">
  <IfModule mod_headers.c>
    Header set Access-Control-Allow-Origin "*"
  </IfModule>
</FilesMatch>

That’s all. All icons have appeared.

@pmoreno, I think your solution is in fact a workaround…

As the error says: You are trying to fetch the font from https://mydomain, while the origin is http://mydomain. CORS differentiates between HTTP and HTTPS.

From the CORS docs on mdn:

[…] A web application executes a cross-origin HTTP request when it requests a resource that has a different origin (domain, protocol, or port) from its own.

There are more HTTP and other issues on you site:

  • http://fonts.googleapis.com/css?family=Open+Sans
  • GET https://prueba.juanvillen.es/js/wow.min.js net::ERR_ABORTED 404
  • <a href="http://grav.juanvillen.es/#contacto">formulario</a>
  • <a aria-label="learn more about cookies" role="button" tabindex="0" class="cc-link" href="http://juanvillen.es/cookies" rel="noopener noreferrer nofollow" target="_blank">Saber más</a>
  • plus some more references to insecure external HTTP sites

By the way, is there any reason why I cannot open the context menu of the page?