• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

XF 2.0 Page content not displaying on child style.

#1
I've got a child of the default theme that I'm tweaking the colors on. I just noticed that page content on the home page doesn't display on it, whereas it does display on the default theme.

Here's the really strange part. The links under the home tab (links and board rules), they display just fine on both styles, and both of them are pages.
 

Attachments

Chris D

XenForo developer
Staff member
#2
Go to Admin > Appearance > Styles > Find the child style and click the ... menu > Click "Customized components"

Does the page template appear as customised in the child style? If so, that will be the reason. If you want to ensure that changes made to the page content apply to all children, then you should ensure that you only edit the page content in the parent/default style.
 
#3
Go to Admin > Appearance > Styles > Find the child style and click the ... menu > Click "Customized components"

Does the page template appear as customised in the child style? If so, that will be the reason. If you want to ensure that changes made to the page content apply to all children, then you should ensure that you only edit the page content in the parent/default style.
Wouldn't that cause my changes to be overridden every time I installed an update?
 

Chris D

XenForo developer
Staff member
#4
Wouldn't that cause my changes to be overridden every time I installed an update?
Nope. Bear in mind we're talking about a totally custom page template here - we have no reason to ever delete or attempt to modify templates that you have essentially created yourself. But, even if it wasn't, and it was a default template (like thread_view or PAGE_CONTAINER) we have a system in place to protect custom changes and merge them IF you install an update in which we have modified the template.
 
#5
No, it would if you edited the Master Style, not the Parent.
Okay, now I'm really confused. I thought the parent WAS the master. I was really careful not to edit it directly. I'm coming from WP and phpBB, and editing the parent is a big no no in those.

So just to be certain, I should be editing the one that says "Default Style" in the screenshot below:
 

Attachments

Chris D

XenForo developer
Staff member
#6
Just to keep it simple: edit whichever style you want as long as it isn't called "Master style" (in normal circumstances, you won't see this).

Let's just focus on this for now:
Go to Admin > Appearance > Styles > Find the child style and click the ... menu > Click "Customized components"

Does the page template appear as customised in the child style? If so, that will be the reason. If you want to ensure that changes made to the page content apply to all children, then you should ensure that you only edit the page content in the parent/default style.
Have you customised the page template in the "Flat Dark Earth" style? Is it listed there? If so, just revert it and that should sort the problem out.
 
#7
Just to keep it simple: edit whichever style you want as long as it isn't called "Master style" (in normal circumstances, you won't see this).

Let's just focus on this for now:

Have you customised the page template in the "Flat Dark Earth" style? Is it listed there? If so, just revert it and that should sort the problem out.
Fixed it!

So should I remove the child from the parent and delete "Default Style?"
 

Chris D

XenForo developer
Staff member
#10
Do it in two parts. Remove it from its parent first. Then check that everything still looks/works as expected, then if you're happy, go ahead and remove the parent.
 
#11
Do it in two parts. Remove it from its parent first. Then check that everything still looks/works as expected, then if you're happy, go ahead and remove the parent.
Okay, when I did, the default Xenforo logo popped up in the header. The logo isn't displaying in the parent (former parent). Does that mean anything?
 

Chris D

XenForo developer
Staff member
#12
It likely means you edited some things in the (former) parent style and then you edited some things in the child style. This is a fairly good example of why it's perhaps sensible to only have a single style, things can get confusing when you're potentially editing multiple styles.

Any changes you directly made to the Default style will need to be recreated in the old Child style.