• Do not register here on develop.twiki.org, login with your twiki.org account.
• Use View topic Item7848 for generic doc work for TWiki-6.1.1. Use View topic Item7851 for doc work on extensions that are not part of a release. More... Close
• Anything you create or change in standard webs (Main, TWiki, Sandbox etc) will be automatically reverted on every SVN update.
Does this site look broken?. Use the LitterTray web for test cases.

Currently:

  • Currently no known bugs


JavaScript debugging tips: CC, TW
  1. Use Firefox with the 'Venkman' debugger to catch errors or IE with Microsoft Script Debugger installed (available free for registered owners of MS products available from here)
  2. IE debugging is a lot easier if you have Visual Studio
  3. Mozilla and IE show different errors, because their intepretation of the DOM is different. You must test on both!
  4. If you see an error, please try to describe a testcase for regenerating it, and give as much information as possible! JavaScript errors can can a long time to track down.


On the error in "Edit settings": This one is a mystery to me. The template contains an element with name='text' (i.e., the textarea) so the document.main.text.focus() should succeed. I am really puzzled by this one. -- TW


however, the settings.pattern.tmpl doesn't contain a form named main; it's called saveSettings.

so, there are three choices that i know of:

  1. change the name from saveSettings to main.
  2. change document.main.text.focus() to document.getElementById( 'text' ).focus()
    • actually, even safer would be: var text = document.getElementById( 'text' ); if ( text ) { text.focus() }
  3. change all of the scripts in settings.tmpl from document.main... to document.saveSettings... --WN


Fixed
  • Edit settings: in initForm(): document.main.text.focus(); 'document.main.text' is null or not an object
based on WN's suggestion. SVN 6599 --TW
Removed the following, as I cannot see it anywhere but in bugs web. --TW
  • Edit: in initForm(): document.main.text.focus(); Cannot change focus. May only be in bugs web
    • No, I've seen it in other installations, in webs where the textarea is enabled CC
    • This shows up whenever the textarea is not present. You can then not set focus to that item. In the bugs web, for example, the text area is hidden using JavaScript which causes this error. It would be much better to use action=editform to hide the text which uses a template that does not involve setting focus.


Someone has added a "focus" macro to switch this off. I don't get any errors now, so I'm closing this. CC
Now these have been fixed:
  • Edit form (using action=form): Error: 'classes' is null or not an object Refers to function getClassList
  • Edit newly created XXXXX topic: Error: 'classes' is null or not an object Refers to function getClassList


typing in the topic textarea produces Error: window.event has no properties

SVN:6665

-- WN


Error: element has no properties
Source File: http://develop.twiki.org/~develop/cgi-bin/edit/Bugs/ItemXXXXXXXXXX?templatetopic=Bugs.HideTextarea&formtemplate=Bugs.ItemTemplate&_T=0501092906&action=form
Line: 96

click on this link to produce the error: http://develop.twiki.org/~develop/cgi-bin/edit/Bugs/ItemXXXXXXXXXX?templatetopic=Bugs.HideTextarea&formtemplate=Bugs.ItemTemplate&_T=0501092906&action=form

WN

SVN 6679 CC


Error identified by WN right above is still happening. --TW
Was a different error, and was on IE only. Fixed by putting a try{} block around the focus-setting call.

SVN 6704

CC


On logon page, initPag() causes an error. -- TW

Mysteriously disappeared... -- TW

ItemTemplate
Summary Remove all JavaScript errors on generated HTML
ReportedBy ThomasWeigert
Codebase

AppliesTo Engine
Component

Priority Urgent
CurrentState Closed
WaitingFor

Checkins 6599 6665 6679 6703 6704 6920
Edit | Attach | Watch | Print version | History: r26 < r25 < r24 < r23 < r22 | Backlinks | Raw View |  Raw edit | More topic actions
Topic revision: r26 - 2005-11-13 - ThomasWeigert
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2023 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback