dcsimg
Why is my script's behavior inconsistent?
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Buddhi_Godawatte
Posted On:   Monday, October 1, 2001 12:39 AM

I am using a script to enable/disable a group of radio buttons on a page. I've made browser independent and it works prefectly on my testing machine. However, when a colleague tested it, it did not function as expected. Clicking on the "enable" button once was not enough. She had to click twice. I have tested the code successfully on other machines though. The behavior does not seem consistent with browser version either. It has failed and worked on IE 5.5 as well as 5.0. It also worked fine on the one machine I found running IE 4.0 Any suggestions or comments are much appreciated. Here is the code: Onload function: function primeRecurring(){ if (document.frmPayment.scheduleMode    More>>

I am using a script to enable/disable a group of radio buttons on a page. I've made browser independent and it works prefectly on my testing machine. However, when a colleague tested it, it did not function as expected. Clicking on the "enable" button once was not enough. She had to click twice. I have tested the code successfully on other machines though. The behavior does not seem consistent with browser version either. It has failed and worked on IE 5.5 as well as 5.0. It also worked fine on the one machine I found running IE 4.0


Any suggestions or comments are much appreciated.


Here is the code:


Onload function:





In the HTML Body:

   <<Less

Re: Why is my script's behavior inconsistent?

Posted By:   Firat_Tiryaki  
Posted On:   Monday, October 1, 2001 04:23 AM

Forgive me, couldn't check all of your code. I think no need such a long code for this kind of situation.



Create a global variable such as;
var enablingSwitch=0;



change it with the function onclick of a checkbox



The rest is calling the below function onclick of the radio buttons

function ED()

{

if(!enablingSwitch)this.checked=false;

}

About | Sitemap | Contact