My file structure is as follows:
- Reckless
- ContactFormSelectors
- controllers
- Contacts
- IndexController.php
- Contacts
- etc
- config.xml
- Helper
- Data.php
- controllers
- ContactFormSelectors
My IndexController.php file is very simple:
<?php
require_once Mage::getModuleDir('controllers', 'Mage_Contacts') . DS . 'IndexController.php';
class Reckless_ContactFormSelectors_IndexController extends Mage_Contacts_IndexController
{
public function indexAction()
{
echo 'here';
exit;
}
}
I'd expect the output to be a blank page with 'here' output. This file isn't being loaded at all though, unfortunately.
Here is my config.xml file:
<?xml version="1.0"?>
<config>
<modules>
<Reckless_ContactFormSelectors>
<version>0.0.1</version>
</Reckless_ContactFormSelectors>
</modules>
<frontend>
<routers>
<contacts>
<args>
<modules>
<Reckless_ContactFormSelectors before="Mage_Contacts">Reckless_ContactFormSelectors</Reckless_ContactFormSelectors>
</modules>
</args>
</contacts>
</routers>
</frontend>
<global>
<helpers>
<Reckless_ContactFormSelectors>
<class>Reckless_ContactFormSelectors_Helper</class>
</Reckless_ContactFormSelectors>
</helpers>
</global>
</config>
I have an XML file in /app/etc/modules/Reckless_ContactFormSelectors.xml with the content:
<?xml version="1.0"?>
<config>
<modules>
<Reckless_ContactFormSelectors>
<active>true</active>
<codePool>local</codePool>
</Reckless_ContactFormSelectors>
</modules>
</config>
Logs are empty and hold no clues.
Within System > Configuration > Advanced I can see the module and it is enabled.
Reckless>ContactFormSelectors
folderContacts
undercontrollers
for yourReckless_ContactFormSelectors_IndexController
unless you name itReckless_ContactFormSelectors_Contacts_IndexController
and call the action on the URL "contacts/contacts_index/index"