Click here to Skip to main content
15,921,793 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi all. I've used multiple plugins with different versions in my website but there is a conflict I cant solve. I goggled a lot and applied solutions but they don't work together.I'm elementary in Jquery please help me.
HTML
    <!-- jQuery KenBurn Slider-----------jquery1.7.2--jQuery UI 1.8.5---->
    <script src="SliderRevolution/rs-plugin/js/jquery-ui.js"></script>
    <script src="SliderRevolution/rs-plugin/js/jquery.js"></script>
    <script src="SliderRevolution/rs-plugin/js/jquery.themepunch.plugins.min.js"></script>
    <script src="SliderRevolution/rs-plugin/js/jquery.themepunch.revolution.min.js"></script>
    <script src="SliderRevolution/rs-plugin/js/Slider.js"></script>
<%------------magic line ------------jQuery 1.5.2--------------------%>
    <script src="MagicLine/js/example.js"></script>
    <script src='http://ajax.googleapis.com/ajax/libs/jquery/1.5.2/jquery.min.js'></script>  
 <!-------------dock menu------jQuery 1.1.2---------------------------->
    <script type="text/javascript"  src="./dock/js/jquery.js"></script>
    <script type="text/javascript" src="./dock/js/interface.js"></script>

<!-- jQuery KenBurn Slider-----------jquery1.7.2--jQuery UI 1.8.5---->
Slider.js:
JavaScript
var newjq = jQuery;
newjq.noConflict();
newjq(document).ready(function () {
    newjq('.fullwidthabnner').revolution(
           {
               delay: 5000,
               startheight: 500,
               startwidth: 960,

               hideThumbs: 300,

               thumbWidth: 100,
               thumbHeight: 50,
               thumbAmount: 5,

               navigationType: "both",
               navigationArrows: "verticalcentered",
               navigationStyle: "round",

               touchenabled: "on",
               onHoverStop: "on",

               navOffsetHorizontal: 0,
               navOffsetVertical: 20,

               stopAtSlide: -1,
               stopAfterLoops: -1,

               shadow: 1,
               fullWidth: "on"
           });
});

<%------------magic line ------------jQuery 1.5.2--------------------%>
example.js:
JavaScript
//var $jmagic = jQuery.noConflict(true);
z// DOM Ready
$(function() {

    var $el, leftPos, newWidth;
    
    /*
        EXAMPLE ONE
    */
    
    /* Add Magic Line markup via JavaScript, because it ain't gonna work without */
    $(".hmenu").append("<li id='magic-line'></li>");
    
    /* Cache it */
    var $magicLine = $("#magic-line");
    
    $magicLine
        .width($(".current_page_item").width())
        .css("left", $(".current_page_item a").position().left)
        .data("origLeft", $magicLine.position().left)
        .data("origWidth", $magicLine.width());
        
    $(".hmenu li").find("a").hover(function () {
        $el = $(this);
        leftPos = $el.position().left;
        newWidth = $el.parent().width();
        
        $magicLine.stop().animate({
            left: leftPos,
            width: newWidth
        });
    }, function() {
        $magicLine.stop().animate({
            left: $magicLine.data("origLeft"),
            width: $magicLine.data("origWidth")
        });    
    });
 });

<!-------------dock menu------jQuery 1.1.2---------------------------->
interface.js:
HTML
eval(function(p,a,c,k,e,d)..............)
Posted
Updated 30-Nov-13 22:08pm
v4
Comments
Sergey Alexandrovich Kryukov 1-Dec-13 0:05am    
I did not check it up and cannot tell you exactly if you have some mistake, or it is the inherent problem. If this is really the problem with plug-ins, I would suggest the resolution: find out the conflict of names between plug-ins, take source code of one of them and renames some methods to resolve the conflict.
—SA

HTML
<script src="SliderRevolution/rs-plugin/js/jquery.js"></script>
<script src='http://ajax.googleapis.com/ajax/libs/jquery/1.5.2/jquery.min.js'>
<script type="text/javascript"  src="./dock/js/jquery.js"></script>

These three are the same. So, remove any two lines and include only one file.
 
Share this answer
 
Comments
Sergey Alexandrovich Kryukov 1-Dec-13 0:35am    
Ha-ha, really? What a funny case! Good catch, my 5.
—SA
Thanks a lot Sergey. :)
mit62 1-Dec-13 1:47am    
I removed lower versions but didn't work
What did not work? What is the problem? Please see the FireBug console window in FireFox for any errors.
if there are any, then correct them.
mit62 1-Dec-13 10:12am    
I remove jquery1.5.2 in Magicline part and it works with jquery1.7.2 in slider part. then I remove jquery1.1.2 from Dockmenu part but that dosnt work. now I have this:

<!-- jQuery KenBurn Slider-----------jquery1.7.2--jQuery UI 1.8.5---->
<script src="SliderRevolution/rs-plugin/js/jquery-ui.js"></script>
<script src="SliderRevolution/rs-plugin/js/jquery.js"></script>
<script src="SliderRevolution/rs-plugin/js/jquery.themepunch.plugins.min.js"></script>
<script src="SliderRevolution/rs-plugin/js/jquery.themepunch.revolution.min.js"></script>
<script src="SliderRevolution/rs-plugin/js/Slider.js"></script>
<link href="SliderRevolution/rs-plugin/css/captions.css" rel="stylesheet" />
<link href="SliderRevolution/rs-plugin/css/settings.css" rel="stylesheet" />
<link href="SliderRevolution/style.css" rel="stylesheet" />
<%------------Magicline ------------jQuery 1.5.2--------------------%>
<script src="MagicLine/js/example.js"></script>
<!-------------Dockmenu------jQuery 1.1.2---------------------------->
<script type="text/javascript" src="./dock/js/interface.js"></script>
<link href="./dock/css/style.css" rel="stylesheet" type="text/css" />

maybe I must use some code in interface.js to avoid conflicting.but I dont now how


eval(function (p, a, c, k, e, d) { e = function (c) { return (c < a ? '' : e(parseInt(c / a)))......split('|'), 0, {}))

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900