'Myriad pro font is not shown properly

I have used myriad pro font in my website and this font is uploaded on server and i have given link for this font as below

@font-face{
    font-family: "Myriad-Pro";  
    src: url(http://www.anaveer.in/honda/font/MYRIADPRO-REGULAR.OTF) format("truetype");
}

but still this font is not show, is there any another way of solution for this problem?

css


Solution 1:[1]

I have tested on my local machine. the browser is chrome.

<html>
<head>
<style type="text/css">
@font-face{
    font-family: "Myriad-Pro";  
    src: url(http://www.anaveer.in/honda/font/MYRIADPRO-REGULAR.OTF) format("truetype");
}
body{ font-family:Myriad-Pro; }
</style>
</head>
<body>
This should be in myriad-pro font
</body>
</html>

this worked perfectly. (I think the font is what I am pasting a screenshot).

Just pasted your code and a static html

Probably you may wish to let us know which browser is giving a hickup to you. Either way, since you are uploading it to your server, I suggest you have a look at font-squirrel's all-type-fonts and their css generated for you.

Solution 2:[2]

Check first that you have a legally valid license to use Myriad Pro on the Web. Then check the font vendor’s instructions on such use.

Specific things to note:

  • IE does not support OTF for Web fonts, you need other formats.
  • The font files should reside on the same server as the page using them, or else the server hosting them must allow cross-site use.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Siva Tumma
Solution 2 Jukka K. Korpela