Heinrich
Heinrich

Reputation: 1761

Magento add Flexslider to homepage

I am using the Bitnami Magento https://bitnami.com/stack/magento stack and trying to add flexsliderto the homepage. I'm getting this error in my custom.js file:

SCRIPT438: Object doesn't support property or method 'flexslider'

for the Home Page I've added this to the CMS->Pages->Design-Custom Layout Design XML

<reference name="head"> 
    <action method="addCss"><stylesheet>css/flexslider.css</stylesheet></action>
    <action method="addJs"><script>jquery/jquery.min.js</script></action>
    <action method="addJs"><script>flexslider/jquery.flexslider-min.js</script></action>
    <action method="addJs"><script>flexslider/custom.js</script></action>
</reference> 

All the scripts are loading I've verified with the browser debugger console

This is the custom.js script

$.noConflict();

jQuery(window).load(function () {
    jQuery('.flexslider').flexslider();
});

This is in CMS->Pages->Content for the homepage

<div class="flexslider">
    <ul class="slides">
    <li><img src="Big.jpg" alt="" /></li>
    <li><img src="Big1.jpg" alt="" /></li>
    <li><img src="Big2.jpg" alt="" /></li>
    </ul>
</div>

Another interesting thing is that when I change the Custom Theme on the page design to anything else besides the rwd default it will load the slider correctly.

Upvotes: 1

Views: 2880

Answers (2)

PedroKTFC
PedroKTFC

Reputation: 745

I followed the instructions here https://www.youtube.com/watch?v=AmiM4oWGrLI and got it to work on my site. Your approach seems sound so I suspect there's some sort of conflict with rwd default. Have you Firebuged it to eliminate conflicting classes/ids?

Upvotes: 1

Heinrich
Heinrich

Reputation: 1761

There is a slider that comes with the RWD theme and I am using that now. This article explains how to use it.

http://www.creare.co.uk/new-features-magento-ce-1-9-responsive-theme#slider

Upvotes: 1

Related Questions