I'm trying to create an ajax call to a custom controller.
I've been following: http://www.atwix.com/magento/ajax-requests-in-magento/ - which gives a brief example of how to create.
So I have the following files:
app/etc/moudles/BM_Sidebar.xml
<?xml version="1.0"?>
<config>
<modules>
<BM_Sidebar>
<active>true</active>
<codePool>local</codePool>
</BM_Sidebar>
</modules>
</config>
app/code/local/BM/Sidebar/controllers/IndexController.php
class BM_Sidebar_IndexController extends Mage_Core_Controller_Front_Action {
public function indexAction() {
echo "test data";
}
}
app/code/local/BM/Sidebar/controllers/etc/config.xml
<?xml version="1.0"?>
<config>
<modules>
<BM_Sidebar>
<version>0.1.0</version>
</BM_Sidebar>
</modules>
<frontend>
<routers>
<sidebar>
<use>standard</use>
<args>
<module>BM_Sidebar</module>
<frontName>carfilter</frontName>
</args>
</sidebar>
</routers>
<layout>
<updates>
<sidebar>
<file>sidebar.xml</file>
</sidebar>
</updates>
</layout>
</frontend>
</config>
I'm struggling to work out exactly what I'd need to put into sidebar.xml
Do I need to create a block class?
Thanks