Welcome visitor
* Login
* Register
It is currently May 19th, 2019, 8:19 am
All times are UTC [ DST ]
* Search
View unanswered posts - View active topics

FORUMS » Client Side » JavaScript



Post new topic Reply to topic  [ 2 posts ] 
Author Message
  call a function from inside a function
PostPosted: July 17th, 2009, 8:08 pm 
User avatar

Posts: 42
hey, i got a script that is a bit complicated so i split it into many separate functions. Now my problem is that i only know how to call one function at a time, how can i call one function after another and pass a value from the previous unto the current?


Top
 Profile  
 
  Re: call a function from inside a function
PostPosted: July 17th, 2009, 8:15 pm 
User avatar

Posts: 137
<script>
function one(){var a='auto'; two(a);}
function two(brand){var b='bmw'; alert(brand+' '+b);}
</script>
and you just need to call "one" function


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

FORUMS » Client Side » JavaScript


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron