Closed ltrtuan closed 3 years ago
You should use the original Bootstrap JS code for all browsers except IE11. This projects code is only intended to be used with IE11.
Sorry to bothering you again. Chrome is working now, i have to include original Bootstrap js. Modal in IE11 is working too, But in IE11 , the function 'getOrCreateInstance' of Modal is not working. I need hide current modal to open another modal
var myModalElHide = document.getElementById(idHideModal);
var modal = bootstrap.Modal.getOrCreateInstance(myModalElHide );
modal.hide();
var myModalElShow = document.getElementById(idShowModal);
var modal = bootstrap.Modal.getOrCreateInstance(myModalElShow );
modal.show();
heya, sorry I'm not sure if I can help with that right now. This project was intended to focus on the CSS side of things while using polyfills to get main JS functionality. I don't have any intention to work on writing or maintaining any custom JS to address certain issues for IE11.
One thing you could consider trying is to use Babel to convert the latest Bootstrap JS to IE11-compatible code. Check this comment on another issue for details with a link to example code: https://github.com/coliff/bootstrap-ie11/issues/54#issuecomment-866098631
Ok thanks so much
But i have error in Chrome This is my code
The error is Uncaught TypeError: bootstrap.Modal.getOrCreateInstance is not a function If i use original bootstrap.js it works normally