jQuery. How to get attribute back?
I removed from div -> $(‘#actionDivR’).removeAttr( “onmouseup”); AND I want to know how to return this attribute back.
I need Enadle/Disable functionality of DIV.
###############################
First off,
###############################
I need to disable reaction on mouseup while javascript processing data AND get it back when javascript finishes processing data. I need This DIV visible at every time, but need reaction on event only when JavaScript isn’t running.
PS. I don’t want to interrupt javascript while it is processing data.
- Category: JQuery Questions
I removed from div -> $(‘#actionDivR’).removeAttr( “onmouseup”); AND I want to know how to return this attribute back.
I need Enadle/Disable functionality of DIV.
###############################
First off,
###############################
I need to disable reaction on mouseup while javascript processing data AND get it back when javascript finishes processing data. I need This DIV visible at every time, but need reaction on event only when JavaScript isn’t running.
PS. I don’t want to interrupt javascript while it is processing data.
Other Questions
Login
Search
Recent Comments
- dgdg_dasdad on How does JQUERY DIFFER FROM JAVASCRIPT ? WHAT IS ITJQUERY ?
- Anas Imtiaz on How does JQUERY DIFFER FROM JAVASCRIPT ? WHAT IS ITJQUERY ?
- David D on How does JQUERY DIFFER FROM JAVASCRIPT ? WHAT IS ITJQUERY ?
- Wolfman on How does JQUERY DIFFER FROM JAVASCRIPT ? WHAT IS ITJQUERY ?
- TnT on Having a Jquery PHP problem?


no1home2day
Posted 10 months ago
I THINK I’m understanding your question. If so, this MIGHT be what you’re looking for; if not, sorry
In jQuery, everything can be summed up in two steps: Get something, do something with it.
In the CSS, you would have something already there, then in the jQuery, you would add the class, or even toggle it.
Here’s an example:
CSS:
.big {
… font-size: 400%;
… width: 500px;
… height: 500px;
… line-height: 100%;
}
jQuery:
$(document).ready(function(){
… $(‘#animate’).click(function(){
… … $(‘.box’).toggleClass(‘big’, 2000);… … // 2000 is the time delay
… }) ;
})
You could also use .addClass.
(Note the series of dots (… ) is actually spaces, because if I used actual spaces, yahoo would remove them.)
I HOPE this is what you’re looking for. Good luck, and “happy programming”.