by Greg Travis
Aug 28, 2006
Page 3 of 3
These are the functions defined in talkback.js:
- tb_wrap( fun ) This function puts the function fun inside a wrapper, which traps any exceptions and offers the user a chance to send them back to the developers. When an exception occurs, it adds the Error object to a list of exceptions and offers the user a submission link. If any further exceptions happen, it will add them to the list of exceptions and the submission link as well.
- tb_show_talkback_link() This function shows a small floating window that offers the user a chance to submit an error:
An error has occurred in this page. To report this error, please click here:
This window is created only the first time an exception occurs, and it stays on top of other window content. If further exceptions occur, their information is added to the existing mailto: link.
- tb_set_link_contents() Each time an exception is thrown, it is added to a list. Then, the entire list is scanned for useful information, which is then packed into a mailto: link. This link is shown the first time an exception is thrown, and stays up from then on.
Greg Travis is a Java programmer and technology writer, living in New York City. After spending three years in the world of
high-end PC games, he joined EarthWeb, where he developed new technologies with the then-new Java programming language. Since 1997, he has been a consultant in a variety of Web technologies.