What Works in Caja?
This is a brief overview of what's expected to work in Caja currently.
Browsers Supported
- Firefox 3.0 and 3.5 work pretty well.
- Safari 3 and 4 work pretty well.
- IE 7 and 8 work ok.
- IE 6 is a little flaky.
- Opera 9 and 10 probably work, but are not tested much.
HTML and CSS
Caja supports most of the HTML 4.01 and CSS 2.1 specs, as well as some common browser extensions. Caja tends to adhere more closely to the specs than browsers do, so it may warn about or reject nonstandard extensions that would normally work in browsers.
YML
All YML tags work with Caja.
DOM manipulation
Caja provides proxied access to the DOM. If you look under the
hood, you can see that you're actually manipulating instances of
TameDocument, TameNode,
etc.
Many of the common DOM operations work, such as
document.getElementById(),
document.createElement(),
node.firstChild, etc. However, Caja does
not implement the complete DOM spec, so uncommon
operations may not work yet.
Note that document.write() is
deliberately
not supported, as explained
below. Setting and
getting innerHTML is
supported.
Events and Timers
Most event handlers work. You can attach handlers with HTML
onevent= attributes, or with the DOM
addEventListener method, or by assigning to the
node.onevent property.
Note: node.onevent='...' will not work. The
value must be a function.
the window.setTimeout and
window.setInterval methods both work.
Note: event.fromElement is
IE specific and is not supported by Caja.
Instead, use event.target or
event.relatedTarget, depending on the
event type.
OpenSocial 0.8
Most of our OpenSocial 0.8 support is explicitly whitelisted for use in Caja. We're not supporting OpenSocial 0.7. If you get runtime "Not readable" errors related to OpenSocial objects, check if you're using an OpenSocial 0.7 interface that disappeared in 0.8.

