When I go to set my Drupal 7 site's front page (Administration » Configuration » System » Site information) to a basic page that I've created, and then load the front page, nothing is displayed in the content section on the front page except for the site's header (masthead, navigation, search, etc.), footer, and sidebar for that page. Basically, the content of the page won't display when it's set to be the front page. It displays fine when it's not the front page. What gives?
4 Answers
Try viewing the page source to see what is there. Does it match your front page layout file?
Have you modified the front page layout file?
-
I've ran a diff against both files. The files are too different to really extract any meaning. What's clear is that the page content is definitely not being delivered to the browser.– SamCommented Feb 4, 2015 at 17:01
-
Oh... and there was no front page tpl file. For troubleshooting, I created one that is a clone of the page.tpl.php file, named page--front.tpl.php. I'm waiting for the change to be deployed and we'll see if that does anything.– SamCommented Feb 4, 2015 at 17:03
-
UPDATE: Deliberately making a front page template, produced the same results.– SamCommented Feb 4, 2015 at 18:16
-
Install Theme developer module and inspect front page to see what template is being used. Also look at the deeper nested templates for anything not default. Commented Feb 4, 2015 at 18:34
-
Switch back to Bartik temporarily. If it works, then it is theme related, if it does not pobably module related. Commented Feb 4, 2015 at 18:39
If Ben's solution doesn't find the problem, then check how the path aliases work.
I find the front page must be set as node/6 (say - with the correct number).
To find the node number, go to configuration and find the path aliases middle-left.
Hope that helps.
-
Thanks. It is set that way:
node/32
. See my comment above for more.– SamCommented Feb 4, 2015 at 18:14
I can see that you are using YaleSites. That distribution has some very specific custom overrides for the front page. I don't think you can easily replace the content of the front page with a new node. Instead, follow the directions here: http://yalesites.yale.edu/book/adjust-pre-populated-content-your-new-yalesite
If that doesn't work, contact the people at YaleSites directly. They are very helpful.
-
Yep, I am. I've de-Yale-ified the screenshots now though, as I'm pretty sure that's not the issue (and I don't want that to be a distraction). I've built plenty of Yale sites in the past and have never had this problem. At this point, I think it might be a theme issue. Thanks!– SamCommented Feb 5, 2015 at 2:08
Try this in your template file (which can be page.tpl.php OR page--front.tpl.php)
render($page['content']);
I hope it will work.
node/1
node/32
instead of the alias. Interestingly, after the Site Information page saves, it displays the URL alias,programs/identity-considerations
, in place of thenode/32
. But I think that's normal.