Tagged: Fixed Header, logo, not shrinking, Scrolling
-
AuthorPosts
-
October 14, 2014 at 8:07 pm #335724
Please forgive me if this has already been covered… I searched for a good 45-60 mins and could not find anything….
I would like to have the main logo switch to an alternate version of the logo (icon only) when you scroll down and the header shrinks instead of just shrinking the logo….
Is this possible?
October 15, 2014 at 7:00 am #335948Hi redfirestudio!
Thank you for using Enfold.
You can use this on Quick CSS or custom.css:
.header-scrolled .logo a img { display: none; } .header-scrolled strong.logo.bg-logo a { width: 100px; background: url(LOGO IMAGE URI HERE) no-repeat; }
On header scroll, we’ll remove the default logo then replace another logo set as background image. Adjust the width and height.
Cheers!
IsmaelNovember 4, 2014 at 5:43 am #345728I finally got around to trying this… admittedly I’m not the best at CSS/HTML but I’m not sure what I’ve done wrong…
I copied and pasted the CSS you provided to the custom.css and replaced the text inside the parenthsis with the location of the image… but the desired effect does not appear — can you help?
.header-scrolled .logo a img {
display: none;
}.header-scrolled strong.logo.bg-logo a {
width: 100px;
background: url(/wp-content/uploads/2013/04/icon_only.png);
}November 4, 2014 at 7:12 am #345744Hi!
Change this:
url(/wp-content/uploads/2013/04/icon_only.png);
To
url(https://www.YOURSITE.com/wp-content/uploads/2013/04/icon_only.png);
Regards,
ArvishNovember 4, 2014 at 3:06 pm #345866Hi,
Having the same hard time to get this done. Icon instead of logo while scrolling.
I uploaded the logo and the icon just as explained in the settings > header > transparency options. I thought that was the place.
Secondly I followed instructions as above.
Still nothing.
Regards,
Mariken- This reply was modified 10 years ago by Mariken.
November 4, 2014 at 6:04 pm #345970still nothing…. I even tried putting the file in a different location
.header-scrolled .logo a img {
display: none;
}.header-scrolled strong.logo.bg-logo a {
width: 100px;
background: url (http://new.pttrucks.com/wp-content/uploads/2014/11/icon_only.png);
}November 4, 2014 at 6:12 pm #345977Hi!
Please go to Enfold theme options > Header > Header Behaviour and activate shrinking header and code should work fine
Best regards,
YigitNovember 4, 2014 at 7:02 pm #346020That option is already active… the header shrinks as its supposed to… however no logo appears… its BLANK
November 4, 2014 at 9:29 pm #346123November 4, 2014 at 9:37 pm #346129Hi!
Please replace the CSS you have entered with the following:
.header-scrolled .logo a img { display: none; } .header-scrolled strong.logo a { width: 100px; background: url(https://new.pttrucks.com/wp-content/uploads/2014/11/icon_only.png) no-repeat; } .header-scrolled strong.logo{ padding-top: 10px; }
Cheers!
ArvishNovember 4, 2014 at 10:04 pm #346157That did it thanks!
November 4, 2014 at 10:49 pm #346192Arvish,
My issue was the same. And solved thanks to you and Yigit.
:)- This reply was modified 10 years ago by Mariken.
-
AuthorPosts
- The topic ‘Alternate "small" logo’ is closed to new replies.