Using multiple jquery-ui versions

We have sites using jQuery UI, and one of the sites includes some parts from another site. These parts are built on the jQuery UI Accordion, but I cannot download both versions of the user interface. One of them is user assembly 1.8.11, the other is the full version (full download will not be)

any suggestions?

+3
source share
3 answers

Read the documentation for the JQUERY interface. You cannot use two versions of the user interface without specifying CONTEXT for each of them.

This allows you to use multiple user interfaces on the same page, for example.

, .

, , javascript, , , JQUERY UI, .

0

. - .

jQuery, noconflicted:

<script src="//ajax.googleapis.com/ajax/libs/jquery/1.9.0/jquery.min.js"></script>
<script type="text/javascript">
  var $jnine = jQuery.noConflict();
</script>

jQuery $jnine .

jquery-ui-1.10.0.custom.min.js. . , . Notepad ++, , .

(jQuery), , ($jnine) noConflict().

<script src="//ajax.googleapis.com/ajax/libs/jquery/1.9.0/jquery.min.js"></script>
<script type="text/javascript">
  var $jnine = jQuery.noConflict();
</script>

<script src="js/jquery-ui-1.10.0.custom_jnine.min.js"></script>

jQuery jQuery ui $jnine

Rememver: , script , jQueries, .

+4

ui .

<script language="javascript" type="text/javascript">
   var smartDonationsOldJQuery=jQuery;
   var smartDonationsOldCashSign=$;
</script>

<script language="javascript" type="text/javascript" src="http://rednao.com/wp-content/plugins/smartdonations/js/jquery-1.9.1.min.js"></script>
<script language="javascript" type="text/javascript" src="http://rednao.com/wp-content/plugins/smartdonations/js/jquery-ui-1.10.2.custom.js"></script>

<script language="javascript" type="text/javascript">
    var rnSDJQ=jQuery;
    window.jQuery =smartDonationsOldJQuery;
    window.$ = smartDonationsOldCashSign;
</script>

, jquery/jquery-ui, ( , , wordpress). , jquery.

( , ): jquery ui

0

All Articles