-
Place the p tags in different events:
1. Click
2. double click
3. focus
4. Rollover
- $("p).click()
- $("p).dblclick()
- $("p).focus
- $("p).mouseover()
-
Functions to make P appear or disapear? What is the shortcut that does both?
- $("p).hide()
- $("p).show()
- $("p).toggle()
-
What makes things expand up, expand down, or do both. What are the parameters you can set for each?
- $("p).slideUp(speed,callback)
- $("p).slideDown()
- $("p).slideToggle()
- speed is "slow" "fast" "normal" or in milliseconds
- callback is a function that is to be called after the current on is complete.
-
Three functions to change opacity to nothing, something, or to a certain point
- $(selector).fadeIn(speed,callback)
- $(selector).fadeOut(speed,callback)
- $(selector).fadeTo(speed,opacity,callback)
-
What function can you use to make custom animation
animate
-
How does animate work? What for parameters can it tke?
- Defines a CSS property as something different:
- $(selector).animate({params},[duration],[easing],[callback])
-
What function makes things wait?
delay()
-
What is a callback and how is it used?
Callbacks are functions to be called after the intial function completes.
So.... $("p").hide(speed, callback)
-
Place html into a p object
$("p").html(content)
-
Add HTML before or after existing content
- $(selector).append(content)
- $(selector).prepend(content)
-
What is the difference between before/after and append/prepend?
before/after is outside the selected element. append/prepend is within the element.
-
Adjust the width or height of an object
$(selector).height(value)Set the height of matched elements$(selector).width(value)Set the width of matched elements
|
|