Overwrite prosilver header

Discussion forum for Extension Writers regarding Extension Development.
Post Reply
User avatar
Dragosvr92
Registered User
Posts: 1450
Joined: Sat Sep 12, 2009 7:27 am
Location: Romania
Name: Dragos Valentin Rădulescu
Contact:

Overwrite prosilver header

Post by Dragosvr92 »

So, i am guessing this would be simple to make.....

Could someone provide an easy/basic extension code that removes the <div class="headerbar"> div with everything that is inside it and replaces it to the code we provide? Is there an event that can do this?
The header is one of the most changed part of styles so if there isnt one, there should be.
Formerly known as TheKiller
3.0| Avatar on Memberlist 1.0.3
User avatar
kinerity
Community Team Member
Community Team Member
Posts: 2740
Joined: Mon Sep 01, 2014 1:00 am
Location: sudo rm -rf /
Name: Kailey Truscott
Contact:

Re: Overwrite prosilver header

Post by kinerity »

Create a new HTML file in your extension named overall_header_stylesheets_after.html and place it in /styles/prosilver/template/event.

Code: Select all

<style>
.headerbar {
    display: none;
}
</style>
The only problem you'll run into is that there are no template events before the navbar that will allow you to place you're own code there.
Kailey Truscott - Community Team
GitHub repositories (including un-released extensions)
User avatar
Dragosvr92
Registered User
Posts: 1450
Joined: Sat Sep 12, 2009 7:27 am
Location: Romania
Name: Dragos Valentin Rădulescu
Contact:

Re: Overwrite prosilver header

Post by Dragosvr92 »

That will just hide the class by html. Its a little messy. I thought most extensions just disable the code with events so it isnt loaded. But i guess i can work with that too.....

It appears that Killbill has requested the event needed for this.
http://area51.phpbb.com/phpBB/viewtopic ... 11&t=47226
Lets hope it gets done in 3.1.4 :D

Btw, your* .. yes. you hate me :P
Formerly known as TheKiller
3.0| Avatar on Memberlist 1.0.3
User avatar
Lumpy Burgertushie
Registered User
Posts: 67937
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: Overwrite prosilver header

Post by Lumpy Burgertushie »

the best way to do this would be with a child style that only contains the overall_header.html file that you want to use.


robert
I'm baaaaaccckkkk. still doing work on donation basis. PM your needs.

Premium phpBB 3.3 Styles by PlanetStyles.net

If nobody is in the forest, does a tree really fall?
User avatar
Dragosvr92
Registered User
Posts: 1450
Joined: Sat Sep 12, 2009 7:27 am
Location: Romania
Name: Dragos Valentin Rădulescu
Contact:

Re: Overwrite prosilver header

Post by Dragosvr92 »

Lumpy Burgertushie wrote:the best way to do this would be with a child style that only contains the overall_header.html file that you want to use.
Yes, i am doing that already, but that will only change the header for that one style.
prosilver and all other installed styles will have their default header. I wanted to try an extension that applies on all of them.
Formerly known as TheKiller
3.0| Avatar on Memberlist 1.0.3
User avatar
MattF
Extensions Development Coordinator
Extensions Development Coordinator
Posts: 5164
Joined: Sat Jan 17, 2009 9:37 am
Location: Los Angeles, CA
Name: Matt Friedman
Contact:

Re: Overwrite prosilver header

Post by MattF »

Extensions can't overwrite or replace template code. You can only do what kinerty or lumpy suggested.
Formerly known as VSEMy ExtensionsPlease do not PM me for support.
User avatar
Dragosvr92
Registered User
Posts: 1450
Joined: Sat Sep 12, 2009 7:27 am
Location: Romania
Name: Dragos Valentin Rădulescu
Contact:

Re: Overwrite prosilver header

Post by Dragosvr92 »

VSE wrote:Extensions can't overwrite or replace template code. You can only do what kinerty or lumpy suggested.
Nah. Then what are the extensions for... ill wait till that event gets merged in the next release. If it does.
Formerly known as TheKiller
3.0| Avatar on Memberlist 1.0.3
User avatar
MattF
Extensions Development Coordinator
Extensions Development Coordinator
Posts: 5164
Joined: Sat Jan 17, 2009 9:37 am
Location: Los Angeles, CA
Name: Matt Friedman
Contact:

Re: Overwrite prosilver header

Post by MattF »

No event will let you replace template code.
Formerly known as VSEMy ExtensionsPlease do not PM me for support.
User avatar
Dragosvr92
Registered User
Posts: 1450
Joined: Sat Sep 12, 2009 7:27 am
Location: Romania
Name: Dragos Valentin Rădulescu
Contact:

Re: Overwrite prosilver header

Post by Dragosvr92 »

VSE wrote:No event will let you replace template code.
No, i meant adding the content before the navbar after i disable the main header with css. ;)
Formerly known as TheKiller
3.0| Avatar on Memberlist 1.0.3
Post Reply

Return to “Extension Writers Discussion”