Welcome to Geeklog, Anonymous Thursday, November 28 2024 @ 02:43 pm EST
Geeklog Forums
Give Blocks On One Side Same Look
Tony
Set 1: blockheader-left.thtml and blockfooter-left.thtml
Set 2: blockheader-right.thtml and blockfooter-right.thtml
Now typically you set a custom template for a block by going:
$_BLOCK_TEMPLATE['<block_name>'] = '<header_template>,<footer_template>';
If you want to do this dynamically for both sides you would add this little bit of code to your functions.php for the theme you are working in:
$result = DB_query("SELECT onleft,name FROM {$_TABLES['blocks']} WHERE is_enabled = 1"
$nrows = DB_numRows($result);
for ($i = 1; $i <= $nrows; $i++) {
$A = DB_fetchArray($result);
if ($A['onleft'] == 1) {
$_BLOCK_TEMPLATE[$A['name']] = 'blockheader-left.thtml,blockfooter-left.thtml';
} else {
$_BLOCK_TEMPLATE[$A['name']] = 'blockheader-right.thtml,blockfooter-right.thtml';
}
}
Enjoy!
The reason people blame things on previous generations is that there's only one other choice.
Anonymous
knuckles
Anonymous
krove
knuckles
As for the rest, if you know the block name you can specify a custom theme as you wish. Here's a sample courtesy of Tony Bibbs as given to me (alter the code to suit your needs):
$_BLOCK_TEMPLATE['whosonline_block'] = 'blockheader- right.thtml,blockfooter-right.thtml';
superdood13
Bananiel
you can see the result on my website.
Greetz Daniel
http://www.bananiel.nl/
anony
I was wanting the right blocks have unique colors in the text and backgrounds (different from the left block text & background colors)
Using GeekLog v1.3.11
Thanks in advance!
- Normal Topic
- Sticky Topic
- Locked Topic
- New Post
- Sticky Topic W/ New Post
- Locked Topic W/ New Post
- View Anonymous Posts
- Able to post
- Filtered HTML Allowed
- Censored Content