Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

JavaScript Forum


You are currently viewing our JavaScript Forum as a guest. Please register to participate.
Login



Reply
(jquey) Apply 2 events in one click
Old 09-13-2009, 12:16 PM (jquey) Apply 2 events in one click
Novice Talker

Posts: 8
Trades: 0
Hi everybody!!

I'm beginning in jquery and although I do understand a bit what the script says, I need help. I have a btn which should call two event at the same time. I would like to apply 2 events in one click. Ok? I figure that this is a very simple sentence, but I can’t get it.

This is what I have:
a <div id:”logo”> in an specific place.
a <div id:”menu”> exactly in the same place (z-index:3000 and display:none)
a button named “call” <a href id=”call”>

What I want:
I would like that id:logo hidde slowly when “call” is clicked but at same time that “menu” appears. I want to do this with effects. Simple effects, just the logo disappears (upwards) slowly and menu appears downwards slowly.

What I’ve done:
Code:
    <script type="text/javascript">
  $(document).ready(function(){
           $("#call").click(function(event){
           event.preventDefault();
           $("#MD_logo").hide("slow");
           });
  
           $("#call").click(function(event){
           event.preventDefault();
           $("#menu").show(2000);
           });
  });
The effects work in IE, though it disappears and appears from the top left corner. Whereas in Mozilla, the effect only works in the menu. The logo simply disappears without effect. Please a litle help will be great. Thank you

tapi is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Reply     « Reply to (jquey) Apply 2 events in one click
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.08330 seconds with 12 queries