Magento Forum

Javascript Accordion Menu
 
redletter
Jr. Member
 
Avatar
Total Posts:  24
Joined:  2008-08-19
Alberta, Canada
 

Greetings,

I am looking to take a simple menu I created using this method : http://www.magentocommerce.com/boards/viewthread/16021/ and turn it into an accordion menu with some nice blind up blind down features.

I looked at using the scriptaculous for implementing the menu as it is already included in the magneto install. This method looks to be very promising. http://www.stickmanlabs.com/accordion/

The problem is I am not very familiar with JavaScript and I just started using magneto so im kind of leary jumping in and editing some of the core files needed to call in my custom js menu.

If anyone could assist with a starting off point on how to integrate the javascript files woulth breaking everything that would be much approciated.

Thanks in advance!

-Edward

 
Magento Community Magento Community
Magento Community
Magento Community
 
Quiddity
Jr. Member
 
Total Posts:  22
Joined:  2008-06-13
 

Were you ever able to set up the accordion menu?

If so, would you mind sharing how you accomplished this

Thx

 
Magento Community Magento Community
Magento Community
Magento Community
 
LeeSaferite
Guru
 
Avatar
Total Posts:  322
Joined:  2007-08-31
Lake City, FL
 

/magento/app/design/adminhtml/default/default/layout/yourmodule.xml

<?xml version="1.0"?>
<layout version="0.1.0">
    <
adminhtml_catalog_product_edit>
        <
reference name="head">
            <
action method="addJs"><script>yourcompany/yourmodule/adminhtml/accordion.js</script></action>
        </
reference>
        <
reference name="js">
            <
block type="adminhtml/template" name="yourcompany_yourmodule_accordion" template="yourcompany/yourmodule/accordion.phtml"></block>
        </
reference>
    </
adminhtml_catalog_product_edit>
</
layout>

That would load:
/magento/js/yourcompany/yourmodule/adminhtml/accordion.js
/magento/app/design/adminhtml/default/default/yourcompany/yourmodule/accordion.phtml

for Adminhtml_Catalog_Product_EditController

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top