The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
From: kangax <kan...@gmail.com>
Date: Sun, 3 Aug 2008 17:26:56 -0700 (PDT)
Local: Sun, Aug 3 2008 8:26 pm
Subject: Re: Removing a style?
On Aug 3, 7:57 pm, "andy.kri...@gmail.com" <andy.kri...@gmail.com>
wrote: > Is there a way to remove a custom-style set on an element such that
This is usually done by assigning an empty string to a property, e.g.:
> the element will return to its stylesheet style? For example, on drag- > and-drop, styles are set on the dragged element and it would be great > if I could call something like > element.removeStyle(['opacity','top,...]) to restore the element to > it's stylesheet style (opacity is easy to reset but there are other > things like top, left, position for which I'd rather not hard-code > values). element.style.backgroundColor = '';
As far as `removeStyle` helper, something like this should work:
Element.addMethods({
});
// then
$(someElement).removeStyle('color', 'opacity', 'position');
--
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
| ||||||||||||||