I've followed this tutorial from the Magento Wiki, but I get a 404 when accessing my front controller.
After doing research, I found this question facing the same problem and I did all the suggested checks, but to no avail. My compiler and cache are disabled, and to discard hardware-related issues I've cleared my browser's cache and cookies, I've tried in Ubuntu 14.10 with Firefox, Windows 8.1 with all major browsers (including Opera) and iOS 8.1.3 with Safari (both on iPad and iPhone). **(EDIT: I've also cleared the /var/cache/ contents)
My idea is to be able to access company.com/distro and display some information in there. For that, I have the following files for my Company_Distro
extension:
/app/etc/modules/Company_Distro.xml
<config>
<modules>
<Company_Distro>
<active>true</active>
<codePool>local</codePool>
</Company_Distro>
</modules>
</config>
/app/code/local/Company/Distro/etc/config.xml
<config>
<modules>
<Company_Distro>
<version>0.1.0</version>
</Company_Distro>
</modules>
<frontend>
<routers>
<company_distro>
<use>standard</use>
<args>
<module>Company_Distro</module>
<frontName>distro</frontName>
</args>
</company_distro>
</routers>
</frontend>
</config>
/app/code/local/Company/Distro/controllers/IndexController.php
class Company_Distro_IndexController extends Mage_Core_Controller_Front_Action {
public function indexAction() {
echo 'Hello';
}
}
Am I missing something? Am I doing anything wrong? Any help will be greatly appreciated.
Thanks.
Best Answer
After trying all your suggestions and doing even more research, I thought I should review the
index.php
file of Magento and I've realised that I had to type the store code in the URL, so nowcompany.com/store_code/distro
seems to work fine.Thanks to Digital Pianist and John Cuthbert for their help. I can't upvote yet due to lack of enough reputation, but I'll do as soon as it's possible.