We build. You grow.

Get best community software here

Start a social network, a fan-site, an education project with oxwall - free opensource community software

Banner image! | Forum

Topic location: Forum home » Development » Themes
Catkin
Catkin Jul 3 '19
Hay folks, I want to do something simple here.

I would like the banner on my theme to only be displayed on the front page, all other pages like photos or profiles I would not like it displayed at the top, how do I do this?


All help appreciated!

Senior Developer Leader
Senior Developer Jul 3 '19
Install this plugin https://developers.oxwall.com/store/item/1484


And add this custom css:


body:not(.controllername) .ow_header_pic{

display:none;

}


That plugin adds the controller name as a class into the body tag, just check the class name that was added into the body html tag and replace "controllername" for the class that was added, all other pages that do not have that class in the will hide the header photo.


Senior Developer.

Senior Developer Leader
Senior Developer Jul 3 '19
I think the index page class is base_index_page, so add this as custom css and see if it works


body:not(.base_index_page) .ow_header_pic{  display:none; }



Senior Developer.

The Forum post is edited by Senior Developer Jul 3 '19
Catkin
Catkin Jul 3 '19

Quote from Senior Developer I think the index page class is base_index_page, so add this as custom css and see if it works


body:not(.base_index_page) .ow_header_pic{  display:none; }



Senior Developer.

With or without the plugin?
Senior Developer Leader
Senior Developer Jul 3 '19
With the plugin installed.

The plugin adds the class "base_index_page" to the body tag.


Senior Developer.

Catkin
Catkin Jul 3 '19
So I have just given this a shot. I admit I must be doing something wrong as its not working for me just now.


Thank you for the support so far!

Catkin
Catkin Jul 3 '19
Nope, my bad!


Got it working now, thank you ever so much Senior Developer!

Senior Developer Leader
Senior Developer Jul 3 '19
I'm glad that it worked.

You are welcome.


Senior Developer.