Lack of interest Globally accessible sidebar data

This suggestion has been closed automatically because it did not receive enough votes over an extended period of time. If you wish to see this, please search for an open suggestion and, if you don't find any, post a new one.

RickM

Well-known member
I (like quite a few others) have found out that if you move the sidebar into its own template, and include it on pages such as threadlist and threadview it breaks and shows errors. Basically because the data it needs to pull (for who's online & stats) is only provided for forum_list.

Might I suggest making the sidebar data variables accessible globally. I can see this causing a ot of headaches as many sites so have a sidebar on all pages. I even tried doing some form of condition saying "if we're on the homepage, include the stats sidebar. Otherwise, continue" but I've found out the template system has no options for this (which is something else that is going to cause problems).

So this is kind of a double feature suggestion:

1 - Make sidebar-stats global

OR

2 - Allow conditional if statements to pick up the name of the current page so we can do something like:

Code:
<xen:if condition="THIS_PAGE == 'forum_list'"> -- INCLUDE STUFF -- </xen:if>

I can see this being HUGELY annoying to work with.


I've had an open development discussion about it with Lawrence here if interested: Cant show stats on sidebar of all pages - so can we use an IF to set which pages its on?
 
Upvote 0
This suggestion has been closed. Votes are no longer accepted.
2 - Allow conditional if statements to pick up the name of the current page so we can do something like:

Code:
<xen:if condition="THIS_PAGE == 'forum_list'"> -- INCLUDE STUFF -- </xen:if>

I can see this being HUGELY annoying to work with.


I've had an open development discussion about it with Lawrence here if interested: Cant show stats on sidebar of all pages - so can we use an IF to set which pages its on?

What do you mean under THIS_PAGE here? Current template? But templates can be xen:included into each other, so what template should be THIS_PAGE?
 
THIS_PAGE would be the current page a user is on. So say for example they were on forum home it would be something like 'home' and for viewing a thread 'threadview'. That way you can determin the type of page, and thus limit the stats to showing on the homepage only.


I know its possible to just change whats in the <xen:sidebar> stuff....but you will be doing it for _every_single_page_ which is not exactly ideal. For now, I've disabled the stats completely as I cant use XenForo until I work this out.
 
Top Bottom