I would like to add a block to my grouped product view and my simple product view. This block will have some nice tooltips for hover states, i'm using a small library with one jquery plugin and one css stylesheet.
I wish to include these two resources in the of magento on only these pages.
- I am running a custom theme;
- Caching is disabled; and
- My files are inside the
Nevertheless I knew one way was to use
layout.xml in my module, at first this didn't work so I thought maybe I needed additional configuration inside my
config.xml to tell Magento about my layout requirements - this too didn't work.
By didn't work what I mean is, my assets weren't loaded.
Please find the attached source below.
<?xml version="1.0"?> <layout> <default> <reference name="head"> <action method="addJs"> <script>vendor/qtip/jquery.qtip.min.js</script> </action> <action method="addCss"> <stylesheet>vendor/qtip/jquery.qtip.min.css</stylesheet> </action> </reference> </default> </layout>
<?xml version="1.0"?> <config> ... <frontend> <layout> <updates> <vendor_rating> <file>layout.xml</file> </vendor_rating> </updates> </layout> </frontend> ... </config>