PDA

View Full Version : Ajax + sIFR :(



achtungbaby
05-11-2006, 02:43 AM
http://cwi.yellowworld.org/vision/test.html

At the top of the page you'll see a few links, click on "A Place." The ajax script will then dynamically load a new page. But for some reason my fonts aren't getting styled by the sifr script...

Any suggestions?

jscheuer1
05-11-2006, 04:12 AM
Simply linking a script to a page is one thing, running it or running any of its functions are a different matter. All loadobjs() does is write a link on the page that links whatever files you set as its parameters to the page. Since, sifr.js is already linked to the page, this doesn't accomplish anything good and may even be a problem if you try running the functions contained in sifr.js later. Except I believe that loadobjs() checks to see if the files are already linked to the page but, it might miss something. In either case, this is the wrong approach. Why not set your fonts using style? This would not need to be linked to the page more than once either but would take immediate effect with no intervention required. If the script has some intrinsic value like allowing non-standard fonts on systems that normally won't support them, then you need to run the script or its appropriate functions after the new content has been loaded by the ajaxpage() function.

ktsixit
06-11-2009, 12:30 PM
jscheuer1, so is it possible to load a page with sifr fonts or not? I haven't figured that out from your post.