jQuery Animate width by percentage?

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
User avatar
JAB Creations
DevNet Resident
Posts: 2341
Joined: Thu Jan 13, 2005 6:44 pm
Location: Sarasota Florida
Contact:

jQuery Animate width by percentage?

Post by JAB Creations »

This is intended to change the element with the content id to have a total width of 100% though it's not working. How is percentage intended to be defined in jQuery?

Code: Select all

 $('#content').animate({width: '100%'},1000)
User avatar
JAB Creations
DevNet Resident
Posts: 2341
Joined: Thu Jan 13, 2005 6:44 pm
Location: Sarasota Florida
Contact:

Post by JAB Creations »

Browsers inherit this automatically but jQuery requires you to set the relative container; lame, Resolved.
Post Reply