Hi guys, how can I change the background only to the homepage. I want to have it different than the other pages. I know there is the: content_height but I want it only on the home page, any advice?
Printable View
Hi guys, how can I change the background only to the homepage. I want to have it different than the other pages. I know there is the: content_height but I want it only on the home page, any advice?
If content_height is the right place to use different background then you have to put condition and use different css styles
and then in the styleCode:Only registered members can view the code.
Hi Mike, you want me to replace this:
<div id="content_height">
{if $pageInfo.Key == 'home'}
{include file='header_home.tpl'}
{else}
{include file='header_main.tpl'}
{/if}
for this:
<div id="{if $pageInfo.Controller == 'home'}content_height_home{else}content_height{/if}" ???
I've looked into this again and i see that content_height is wrong place to edit background. Backgound applied for the body tag of page, and it seems to be not very simple to change.
I think easier solution for you is to copy templates/yourtemplate/css/common.css and make a copy for the home page.
So for home page load common_home.css and for other pages load common.css file
But it may be different for different templates, to change it and use as i said make following change to the header.tpl file
find
replace withCode:Only registered members can view the code.
Be very careful, and always keep backups of original files in case you need to restore it.Code:Only registered members can view the code.
If you can't sort it out on your own please submit a ticket.
Hi Mike, thanks, it works fine!!!
You are welcome Cesar :)
Hello people!
How can implement?
Different background for different pages
Fore example:
Listings page - background #ccc;
My-profile page - background #fff;
Hello Vitalii,
I can suggest you check class in body tag. For each page has individual class.
For home page body has class: home-page
on search page: search-page
check it through console or firebug.
My site Upgraded version 4.5.1. After change style css and logo image, cannot change style front-end.
I remove header square-pattern.png and changed logo image, changed some css code for font, still not change.
WHY?
Best Regards,
http://www.house-myanmar.com/
Hi,
1. At first you need update cache in your browser, click to Ctrl+F5 and check it.
2. Also i see that your webserver use the CloudFlare-Nginx and it cached static content.
In this case you need wait when the static will be updated automatically later or try update it manually via hosting panel.