-
Notifications
You must be signed in to change notification settings - Fork 4.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chosen-container getting width: 0px #1548
Comments
I encountered exactly the same issue, and what solved this me was adding a |
I searched for this issue about 1 hour. I wasnt sure if it come since the latest update to 3.2... i fixed it with chosen.css and width: 220px !important Its not a good solution, it should be fixed with next joomla update... this issue is nearly 1 year old. |
In the code of "chosen.jquery.js" look: container_props = { Then simply do: $("#idControl").chosen({ |
I realize this is a bit old, but I've come up with a marginally better solution (for 1.7.0) by adding the following function: function defModalWidth(obj) {
if (obj.container_width() == '0px') {
return '600px';
} else {
return obj.container_width();
}
} and replacing this.container.width(defModalWidth(this)); Anything that chosen thinks should be zero because the modal it's in is hidden will get 600 instead. Seems to work. |
I've the latest version of chose (1.0.0) and I'm getting width: 0px within chosen-container. I have no idea why the function this.container_width() has been returning "0px". Someone could help me?
note: I'm using inside a bootstrap modal which shows on the fly
note2: I must call modal() and then call chosen() to not get fail
The text was updated successfully, but these errors were encountered: