The other day in Is it possible to have a single WordPress installation with multiple domain names and multiple databases? we explained how to install, on a single WordPress installation, several websites with more than one domain name and with different databases, which is always very interesting, but after which some problem may come up for us, like this one we are explaining today.
If we want to make use of embedded fonts in the code of our CSS style sheet, the first thing we are going to need is the typeface we want to use, and to put it through some embedded font generator, such as the fantastic Font Squirrel. There we will get everything we need: the typeface converted to the EOT, SVG, OTF or TTF and WOFF formats, and a CSS style sheet, all ready to upload to our server. Basically the content of the style sheet is very similar to this piece of code for the font of our symbol:
The problem comes up for us when we want to use that same piece of code on a different domain name, since the font we want will not be used, but rather the one that is set by default in the main style sheet and that is installed on the computer running the web browser.
How do we solve it?
Very easily, we only have to add a small piece of code to our .htaccess file, specifically this code:
Thanks to this small modification, we are not going to have any kind of problem sharing our embedded fonts in the style sheets across all our domain names.
As always, we hope this small solution to a big problem is useful to you.
Related posts
Comments





