Display piece of code on mainpage and paged pages

charliebrown

New Member
Hello,

I'm currently using {infront}code{/infront} but that displays my desired advert only on the mainpage. I'd like to display it on other pages 2,3,4... etc as well (and still exclude the stats page and such)

Any piece of code for that?

Thanks
 

Basti

Administrator
Staff member
Try table_wrapper.html
that is the file to display stuff for whole ranking
 
Last edited by a moderator:

kapearl

Member
I'm trying to achieve this same thing (show something on the ranking pages & custom pages but not on profile/stat pages) but including {$premium_list} & {$featured_member} template tags. table_wrapper.html displays everything I add correctly except for {$premium_list}{$featured_member} . I get a styled box with no content.

Is there something else I need to do to get table_wrapper.html to show template tags or should I put my code in a different template file?
 

Basti

Administrator
Staff member
That is because the individual files from sources folders are called before the main skin file, where those 2 tags reside in. They simply not exist when table_wrapper is called.

One fix would be to swap it, but pls be aware, this could have side effects.
index.php find
Code:
// Set main skin file
$skin = new main_skin('wrapper');

//Hook Location
eval(PluginManager::getPluginManager()->pluginHooks('main_skin'));
Cut that ( not copy ), and paste it a bit above, before this line
Code:
// Require the appropriate file
If you want you can beta test this change, makes a bit more sense

Code not working, see posts below, do not use this!
 
Last edited:

Basti

Administrator
Staff member
That is because the individual files from sources folders are called before the main skin file, where those 2 tags reside in. They simply not exist when table_wrapper is called.

One fix would be to swap it, but pls be aware, this could have side effects.
index.php find
Code:
// Set main skin file
$skin = new main_skin('wrapper');


//Hook Location
eval(PluginManager::getPluginManager()->pluginHooks('main_skin'));
Cut that ( not copy ), and paste it a bit above, before this line
Code:
// Require the appropriate file
If you want you can beta test this change, makes a bit more sense
Found the first bug with this, which doesnt seem to be fixable, on admin backend, edit member, this change causes the database query to grab random username data.

So, whoever is using this, please revert the change, we have to find some other way for this
 
Top