2

In page.xml, I added jQuery in page.xml :

<action method="addJs">
  <script>lib/jquery/jquery-2.1.3.min.js</script>
</action>
<action method="addJs">
  <script>lib/jquery/noconflict.js</script>
</action>

However, I have to remove jQuery in One Page Checkout page, which is controlled by checkout.xml. How can I remove the jQuery in One Page Checkout pages?

I'm using Magento 1.9.1.

1 Answer 1

5

you can try with this with local.xml

<checkout_onepage_index>       
    <reference name="head">            
        <action method="removeItem">
            <type>skin_js</type>
            <name>lib/jquery/jquery-2.1.3.min.js</name> 
        </action>
    </reference>
</checkout_onepage_index>

if you wish to remove from js folder not skin

<checkout_onepage_index>       
    <reference name="head">
        <action method="removeItem">
            <type>js</type>
            <name>lib/jquery/jquery-2.1.3.min.js</name>
        </action>    
    </reference>
</checkout_onepage_index>
9
  • Already tried this. Even if I cleared all the caches, the jQuery lines are still there. Note that the jQuery is at {Magento_Dir}/js/lib/jquery/jquery-2.1.3.min.js, not in skin folder.
    – Raptor
    Aug 26, 2016 at 10:48
  • i dont want to i have already added mine see my descriptive answer not like you to paste from other answer
    – liyakat
    Aug 26, 2016 at 10:53
  • no need to add <checkout_onepage_index translate="label"> translate label again in local.xml , you are just copied from net and added to your answer, i can't just stop on you to laugh
    – liyakat
    Aug 26, 2016 at 10:54
  • 1
    Thanks man, it works like charm ! (p.s. edit history of his answer will tell... lol)
    – Raptor
    Aug 26, 2016 at 10:58
  • @Raptor, Thanks a lot i will but another person who just know to search on web and answer will not edit it.:D like ahmed
    – liyakat
    Aug 26, 2016 at 11:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.