Comments (6)
I'm getting the same error in a similar situation. I have a SelectBox on the page, and then I open a lightbox with inline html and I call SelectBox only on content within the lightbox. When I close the lightbox the SelectBox on the page no longer works.
I've tried your suggestion but it doesn't seem to be working. Do you mean to unbind any events I have that call SelectBox or Completely Destroy them?
EDIT: I fixed my issue by being more specific with my selectors. When I was closing the lightbox, i was trying to clear all selectboxes and then create them again. After being more specific with all my selectors i just 'destroy'ed only the ones in the lightbox and all good now.
from jquery-selectbox.
Same, if you destroy just the ones you remove, it works. ew.
from jquery-selectbox.
comment out "if( select.data('selectBox-control') ) return false;" in init method helps and have no drastic side effects for usage at my projects. But have not looked, where this could make problems.
from jquery-selectbox.
Same problem,
confirming $('select').selectBox('destroy');
helps as workaround.
from jquery-selectbox.
This is because the settings are stored in the original SELECT element, so when you say $('SELECT').remove() you remove the native control without removing the UI control.
This is a tradeoff for using UI controls. jQuery UI's button control is a similar example: you need to use .button('disable') instead of .prop('disabled', true).
JavaScript can only be so powerful :P
from jquery-selectbox.
Great plugin!
debugging the code, I found that adding a simple null check solves the problem.
if ( typeof(settings) == "undefined") { return; }
should be used twice. in "hideMenus" and "showMenus".
read more at my blog
from jquery-selectbox.
Related Issues (20)
- Tab selects don't work in Firefox... HOT 2
- does not support populating values via ajax? HOT 1
- Events are not working HOT 1
- Data not cleared after submission
- It generate two dropdown if attaching jQurey 1.10
- get value of a custom attribute value
- Dynamically adding options HOT 3
- this pluggin does not support on mobile devices HOT 3
- keypress not working for chrome
- autocomplete is not working HOT 1
- valid html attributes
- How can I have 2 or 3 select boxes on the same page? HOT 1
- SelectBox not showing on Android Crome 53.0.2785.124
- Select option
- Bug with jquery 3.1.1 HOT 4
- Label width for RWD
- NPM version? HOT 1
- dropdown list is not shown in few clicks
- laji
- subdropdown HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jquery-selectbox.