concrete5 homepage single page

Permalink
i would like to make my homepage on my clients website a singlepage.
i tried making a home.php both in the theme directory and in the single pages directory.

what am i doing wrong, thank you.

 
mhawke replied on at Permalink Reply
mhawke
I've never tried but I don't think you can. What are you trying to achieve by making your Home page a 'Single Page'? What problem are you trying to solve?
aryeh replied on at Permalink Reply
i'd like to have a controller for the homepage.
mhawke replied on at Permalink Reply
mhawke
aryeh replied on at Permalink Reply
i just tried doing what that guy answered.
i made a page_types directory in the controller directory.
a file in the called home.php (my page type is called home.php)

put inside that file:
<?php 
defined('C5_EXECUTE') or die(_("Access Denied."));
class homeController extends Controller {
...........
...........
...........


that didn't work. any idea what i did wrong? do i need to re-install my theme? thoughts?
mhawke replied on at Permalink Best Answer Reply
mhawke
I've never done what you are doing but you have to name these things correctly. Both references I gave you tell you to name the class in your controller file (the one in [root]/controllers/page_types/home.php) to be:

class HomePageTypeController extends Controller {
.
.
.
}
aryeh replied on at Permalink Reply
thank you so much, you saved me a big hassle!
i also needed to restart my theme for some reason , not sure why but i did. restart as in uninstall and re-install.
mhawke replied on at Permalink Reply
mhawke
Glad to help.

Instead of removing and re-installing, did you try 'Inspecting' your theme again to add the home.php as weyboat mentioned below?
ConcreteOwl replied on at Permalink Reply
ConcreteOwl
To get your home.php file appear in your themes list of templates,
once you have included it in the theme folder (as you have already),
You must then go to dashboard/themes and "inspect" your theme, you should see your new template listed and a select box which should be pre-selected (ticked)
Click Save, you should now find your home.php template when you view the "design" part of the page properties dialog..