In this article we will talk about a rather interesting technology sIFR (Scalable Inman Flash Replacement). By combining Flash JavaScript and CSS on your XHTML page, you can create text that is executed in absolutely any font. At the same time, xhtml is absolutely valid, the text will be highlighted, and the absence of flash or JavaScript will only result in the text being displayed in standard font with CSS styles.
The note does not pretend to an absolutely complete description of the technology, but in the end you are waiting for links to documentation and a small example that you can download in one file and play with it at your leisure. Using sIFR is very simple. Everything is tied to the fact that after loading the page, JavaScript replaces the necessary XHTML elements with Flash, which contains the necessary font.
The page is loaded into the browser.
The Java Script checks for the presence of the Flash player and then searches for the specified tags or classes.
If the client does not have Flash or JavaScript is disabled, nothing terrible will happen. The client will see plain text with styles.
If there is enough, then JavaScript for each specified element will create a Flash object and initiate a replacement.
The built-in Flash Actionscript will load the desired font size 6pt and stretch it to the desired size.
For each font, you only need one Flash file created in a special way. ')
I think the advantages of this method are obvious, but from the shortcomings it is worth noting:
Replaced elements in this way do not participate in the overall selection (if, for example, you pressed CTRL + A in the browser). Not critical, but you can survive.
Background transparency does not always work. If, for example, under the heading there is some complex background. It seems that it depends on the version of the flash-player.
UPDATE: In the comments CurlyBrace suggested an interesting solution in the form of a plugin for jQuery , which further simplifies the development. For which he thanks a lot and my modest plus in karma.