AloisM
January 16, 2019, 9:18pm
1
Hello,
I have setup a custom homepage on my Ghost blog. I have a page created in Ghost web interface named “Home” which is available at /home/.
My routes.yaml file is
routes:
/:
data:
post: page.home
template:
- page
collections:
/blog/:
permalink: /blog/{slug}/
template:
- index
taxonomies:
tag: /tag/{slug}/
author: /author/{slug}/
When i access the page with /home/ everythings is ok but when i access to the root of my website, the page is showing up whithout the header.
Exactly like @damosullivan here : Dynamic Routing with static home page not working as expected - #6 by damosullivan
Do you got some ideas ?
AloisM
January 27, 2019, 1:52pm
2
I haven’t found the source of the problem yet, but I just noticed something curious. When I zoom the display or when I consult on mobile, the header appears well. I also noticed that the background is not the same color as on a classic page. If anyone knows where the problem may come from.
Hello, this is because you changed the home page layout but didn’t change the styles.
To fix the header you need to remove this style specification Casper/screen.css at main · TryGhost/Casper · GitHub .
Also, you need to change the background color of home page article here Casper/screen.css at main · TryGhost/Casper · GitHub .
The last thing, I think, you need to improve is to show the logo in the home page header and remove logo duplicate in the /blog page. To achieve this just change the home
to blog
here https://github.com/TryGhost/Casper/blob/master/partials/site-nav.hbs#L3 .
I hope it will help you!
1 Like
AloisM
January 28, 2019, 5:13pm
4
Hello,
Thank you, it works perfectly!
Bonus question, do you know if it is possible to remove the display of the page name (in my case “home”) only for the home page?
system
Closed
February 11, 2019, 5:17pm
5
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.