Thursday, March 15, 2007

Javascript cell.innerText problem

In JavaScript, cell.innerText is deprecated. If you use it, you may get problem when browsing. I discovered this when I browsed Nanfang daily (my favorite Chinese news publisher) every week. However, the PDF downloading page works with IE only. This is annoying to me, because I always use Firefox. After a short study, I look found the problem is the old JavaScript. Their script codes hasn't been updated for a long time~~. They used the outdated innerText for cell object in JavaScript:
cell.innerText = daily;

It doesn't work with Firefox and should be changed to
cell.innerHTML = daily;

1 comment:

Unknown said...

obj.innerHTML is deprecated too.

greetz. Lim