Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7495215
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T17:59:59+00:00 2026-05-29T17:59:59+00:00

On a Magento installation, I’m trying to insert xml into the Layout Update XML

  • 0

On a Magento installation, I’m trying to insert xml into the Layout Update XML of my home page. I already have some xml in there that is working, but I would like to add a jQuery script to run my slideshow. I had it in page.xml (and was planning to move it to my local.xml at some point), where it was working, but it broke the Add to cart on product pages. So, I thought I would consolidate onto just the main page, and put it into the Layout Update XML. For some reason it isn’t coming through.

<reference name="head">
<action method="addJs"><script>jquery/jquery-1.7.1.noConflict.min.js</script></action>
<action method="addJs"><script>folder/slider.js</script></action>
</reference>

Any ideas why it would work in my page.xml and not in here?

Here is the nesting idea in page.xml

<default translate="label" module="page">
    <label>All Pages</label>
    <block type="page/html" name="root" output="toHtml" template="page/3columns.phtml">
        <block type="page/html_head" name="head" as="head">
            <action method="addJs"><script>prototype/prototype.js</script></action>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T18:00:00+00:00Added an answer on May 29, 2026 at 6:00 pm

    You can do as follows :

    add javascript into local.xml

    <layout version="0.1.0">
    <default>
       <reference name="head">
          <action method="addJs"><script>jquery/jquery-1.7.1.min.js</script></action>
          <action method="addJs"><script>jquery/carouFredSel.js</script></action>
       </reference>
    </default>
    </layout>
    

    then make a custom home page template ( take reference from 1column.phtml ), select this template for homepage from CMS.

    Put the following content in home page “XML Layout Update” section from Design tab.
    Here is mine setting which I remove whole prototype scripts from homepage is because didn’t want.

    <reference name="head">
    <action method="removeItem"><type>js</type><script>prototype/prototype.js</script></action>
    <action method="removeItem"><type>js</type><script>prototype/validation.js</script></action>
    <action method="removeItem"><type>js</type><name>scriptaculous/builder.js</name><params/></action>
    <action method="removeItem"><type>js</type><name>scriptaculous/effects.js</name><params/></action>
    <action method="removeItem"><type>js</type><name>scriptaculous/dragdrop.js</name><params/></action>
    <action method="removeItem"><type>js</type><name>scriptaculous/controls.js</name><params/></action>
    <action method="removeItem"><type>js</type><name>scriptaculous/slider.js</name><params/></action>
    <action method="removeItem"><type>js</type><name>lib/ccard.js</name><params/></action>
    <action method="removeItem"><type>js</type><name>varien/menu.js</name><params/></action>
    <action method="removeItem"><type>js</type><name>varien/js.js</name><params/></action>
    <action method="removeItem"><type>js</type><name>mage/translate.js</name><params/></action>
    <action method="removeItem"><type>js</type><name>varien/form.js</name><params/></action>
    <action method="removeItem"><type>skin_js</type><script>js/prototype.formalize.min.js</script></action>
    <action method="removeItem"><type>skin_css</type><name>css/formalize.css</name><params/></action>
    

    Also, don’t create a specific noConflict page, just put end of the jQuery script which is working well.

    For instance, here is mine :

    jQuery&&define("jquery",[],function(){return f})})(window);var $jQuery = jQuery.noConflict();

    Also, yu should create jquery folder in root js directory, not in skin folder js directory.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a problem with a magento installation. I used Magento ver. 1.5.0.1, community
So, I have the following situation: 1. A fresh installation of Magento 1.6.1 2.
Is there some restrictions of access to store configuration during installation of custom module
There are some Magento Connect extensions that I find myself installing every time I
I have developed an extension that works great on Magento until 1.6 (I'm trying
I have a Magento installation with around 60 attribute sets. I need to add
I have a Magento installation that is using GIT to maintain the code revisions
I have to create a number of new stores inside my Magento installation. One
I have put magento inside a drupal installation in a subdirectory called store. When
I have multi-store Magento installation, and different product prices are set in different stores.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.