JavaScript Editor Ajax software     Free javascripts 



Main Page

For further reference, you can check out the more detailed list you can find at
http://www.kdweb-
pagedesign.com/tut_4.asp
.
So in lieu of depending completely on CSS typesetting, a number of techniques can be used to imple-
ment “crawlable images.” Using client-side JavaScript, you can walk the document tree of an HTML
file and selectively replace text portions with graphical elements after it loads. This is called “text
replacement.”
The following few pages introduce you to two of the most common implementations of text replacement:
?
The “sIFR” replacement method
works by replacing specified text with Flash files. This method is
documented at length at
http://www.mikeindustries.com/sifr/
.
?
Stewart Rosenberger’s text replacement implementation
does the same thing, but replaces the text
with images instead. The images are generated at the server-side by a PHP script. The method
is described at
http://www.alistapart.com/articles/dynatext
.
Using these techniques, spiders will be able to read the text present in the document (because spiders do
not execute the JavaScript code), and human visitors will see either a Flash file or an image containing
the text. This keeps
both
humans and robots happy.
The “sIFR” Replacement Method
We must admit, we love sIFR! sIFR is an acronym for “Scalable Inman Flash Replacement.” It functions
by replacing specified portions of plain text from a web page with a parameterized Flash file on the
client side.
sIFR brings these benefits:
?
sIFR doesn’t require users to have the necessary fonts installed, because the fonts are included
in the Flash file.
?
If a font is used in multiple pages or headings, it’s downloaded by the user’s browser only once.
?
sIFR doesn’t hurt search engine rankings, because the plain text is still right there in your web page.
?
If the user doesn’t have Flash or JavaScript installed, the text is simply rendered as normal text.
Before attempting to use sIFR, here’s what you need to keep in mind:
?
For testing purposes, you can use the two Flash files that ship with sIFR —
tradegothic.swf
and
vandenkeere.swf
. However, if you want to embed your own fonts into
.swf
files,
Font Type
Font Name
Sans-serif
Trebuchet MS
Ve r da n a
130
Chapter 6: SE-Friendly HTML and JavaScript
c06.qxd:c06 10:55 130


JavaScript Editor Ajax software     Free javascripts