If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

Beginner question about pass parameter into function, thanks

In my asp.net page I have a simple javascript function that will create a count down meter, initial value is set to seconds through "var leave =<%=seconds %>;"
originally countertimer has no parameter and everything seems to work;
But I need to add more function there: when the time is up, user will get prompt to either extend the timer or be redirected to another page.

So I tried to add a variable to the function
by changing function CounterTimer() to function CounterTimer(a) and
add a line: var leave = a;

and it seems not working because the value is not passed to inside the function by calling CounterTimer(60) or CounterTimer("60")