Use 2 fonts in a sentence

Asked

Viewed 45 times

2

I have a website that the client asked me to use a type of source for some things and another type for others. And he asked the mail to be all typed (type1) but this type is not @ so he asked the mail to be all type1 but @ with Tipo2 (a bit stupid in my opinion but who am I).

I tried to put the @ inside a but appears below and does not even appear with this Tipo2. Here I will leave the example of how the code is:

<p class="footer_txt"><a href="mailto:[email protected]" style="font-family: edosz;"><img src="images/mail.png">&nbsp;geral<div style="font-family:finger;">@</div>saberinfinito.pt</a></p>

If useful to answer, the font (type1) is edosz.tff and the font (Tipo2) is Fingerpaint-Regular.ttf. And also I leave here the css of both types:

    @font-face{
    font-family: "edosz";
    src: url('edosz.ttf');
}

@font-face{
    font-family: "finger";
    src: url('FingerPaint-Regular.ttf');
}
  • Hello, the ideal is to create a rule that would already identify "@" and automatically change or it would be acceptable to add <span> ?

1 answer

4

Try it like this:

.tipo1 {
    font-family: edosz;
}

.tipo2 {
    font-family: finger;
}

<span class="tipo1">Texto 1</span><span class="tipo2">Texto 2</span>
  • The above example is cool but use class instead of id, another tip and use google web font

  • @joaomarcelo Opa will edit to class

Browser other questions tagged

You are not signed in. Login or sign up in order to post.