How to insert fonts without having to install them on the computer? [closed]

-2

I want to know how to include font types without having to install it on the computer and when you copy it on another pc you can see the font.

    
asked by lili 14.05.2018 в 20:18
source

2 answers

1

I'm not sure I've understood perfectly well but you can try using Google fonts.

Something like this:

<head>
<link href="https://fonts.googleapis.com/css?family=Lobster|Nunito|Pacifico" rel="stylesheet"> 
</head>
<body>
<h1 style="font-family: 'Nunito', sans-serif;">Tipo de fuente NUNITO</h1>
<h1 style="font-family: 'Lobster', cursive;">Tipo de fuente LOBSTER</h1>
<h1 style="font-family: 'Pacifico', cursive;">Tipo de fuente PACIFICO</h1>

</body>

I would give you this as a result:

The other person needs to have internet confection so that it works, otherwise you would have to make reference to typographies locally.

<head>

<style>
@font-face { font-family: Lobster; src: url('Lobster-Regular.ttf'); } 
@font-face { font-family: Nunito; src: url('Nunito-Regular.ttf'); } 
@font-face { font-family: Pacifico; src: url('Pacifico-Regular.ttf'); } 

</style>

</head>
<body>
<h1 style="font-family: 'Nunito';">Tipo de fuente NUNITO</h1>
<h1 style="font-family: 'Lobster';">Tipo de fuente LOBSTER</h1>
<h1 style="font-family: 'Pacifico';">Tipo de fuente PACIFICO</h1>

</body>

The sources should be where you specify it, in this case, in the same place where your index file or your CSS file is if you use one.

    
answered by 14.05.2018 в 20:47
-1

First of all I recommend that in future questions, try to put an example of code, or what you have tried, because just in this case, it is something simple to interpret, but in other situations, A question like this would be very complicated to answer.

Let's go to the topic;

To use sources without having them downloaded to your project, you can use content delivery network or CDN , you would include it from a link, and then use it as if it were inside your project; for example

p
{
  font-family: 'Indie Flower', cursive;
  font-size: 25px;
}
<link href="https://fonts.googleapis.com/css?family=Indie+Flower" rel="stylesheet">

<p>
Esto es un ejemplo
</p>

In this example, use a cdn from Google Fonts .

I hope it's what you needed.

    
answered by 14.05.2018 в 20:31