Status: offline

jlawrence

Forum User
Chatty
Registered: 12/30/04
Posts: 49
Hi all,
I have a couple of blocks that I want to display, but I don't want them on the home page.
Is there a way to tell geeklog to display the blocks in all topics apart from the homepage.

www.plymouthcricketclub.com - providing cricket for all ages in the Plymouth area.

Status: offline

Turner

Forum User
Chatty
Registered: 04/11/05
Posts: 42
I don't think this is easily done (without hacking). From what I can see, it is ALL or ONE.

Status: offline

jlawrence

Forum User
Chatty
Registered: 12/30/04
Posts: 49
Looks like it's hacking time then
www.plymouthcricketclub.com - providing cricket for all ages in the Plymouth area.

Status: offline

jlawrence

Forum User
Chatty
Registered: 12/30/04
Posts: 49
OK, for anyone who cares this is how I did it.
The blocks in question are phpblocks, so in the function phpblock_functionname in lib-custom.php I added the following:
if ( ($_SERVER['SCRIPT_URL']!="index.php") && ($_SERVER['SCRIPT_URL']!="/")){
..... rest of ......
.... function .....
}
return $retval;

So if the url is / or /index.php $retval is empty and so the block doesn't display.
This works a treat.
www.plymouthcricketclub.com - providing cricket for all ages in the Plymouth area.