1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Conflicting libraries

Discussion in 'jQuery' started by DanInManchester, Mar 15, 2012.

  1. #1
    I have included the following scripting libraries

    <script type="text/javascript" src="/libs/jquery/jquery-1.7.4.min.js"></script>
    <script type="text/javascript" src="/libs/jquerytools/jquery.tools_1_2_6.min.js"></script>
    <script type="text/javascript" src="/libs/easyui-1.2.4/jquery.easyui.min.js"></script>

    The elements of functionality on the page work if include jquerytools OR easyUI but if I include them BOTH it breaks.

    EasyUI doesn't embed any code in the page other than the above and I'm assigning classes for it to work.
    jqueryTools uses the familiar

    $(function() {
    // setup ul.tabs to work as tabs for each div directly under div.panes
    $("ul.tabs").tabs("div.panes > div");
    });


    are there any known issues or ways to make sure libraries work together.
    EasyUI is fundamental to my pages.
    I could replace Jqurytools as all I'm usingis the slider / transition effects and the tabs.

    suggestions please?
     
    DanInManchester, Mar 15, 2012 IP
  2. Moxie Technoxy

    Moxie Technoxy Peon

    Messages:
    11
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #2
    You can try using this syntax:

    jQuery[COLOR=#111111](function() {[/COLOR]
    Code (markup):
    instead of

    $[COLOR=#111111](function() {[/COLOR]
    Code (markup):
    I've had a conflict between prototype and jQuery before and that fixed it. What specific error are you seeing?
     
    Moxie Technoxy, Mar 15, 2012 IP
  3. Moxie Technoxy

    Moxie Technoxy Peon

    Messages:
    11
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #3
    You can also try this: jQuery.noConflict();
     
    Moxie Technoxy, Mar 15, 2012 IP
  4. DanInManchester

    DanInManchester Active Member

    Messages:
    116
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    53
    #4
    It's not the frameworks that are conflicting. I'm only working with jquery.
    Both jeasyui and jquerytools rely on jquery.

    If I include one or the other my scripts work. If I include both I start getting object does not support this property or method because one of the libraries (depending on the order in the head) stops registering.
     
    DanInManchester, Mar 15, 2012 IP