I have added Select2 js to provide search capabilities in my wordpress theme setting drop down options to add search -> http://nimb.ws/1QW6id
I have added the following code to my admin options file:
<?php if(is_admin()) { ?>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>
<link href="https://cdnjs.cloudflare.com/ajax/libs/select2/4.0.6-rc.0/css/select2.min.css" rel="stylesheet" />
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/select2/4.0.6-rc.0/js/select2.min.js"></script>
<script type="text/javascript">
$(document).ready(function($) {
$('.option-tree-ui-select').select2();
});
</script>
<?php } ?>
On the admin side this works, but the code conflicts with the admin side media menu. The media menu continuously loads and does not allow the uploading of new images. When I remove the new code, the media functionality begins to work appropriately.
Any ideas on how to fix this?