8
hello,
here's what i'm using :
on my website, 'news' module is used for the top page.
I want to display a block on top page only, not on others pages of this module.
top page =
http://www.site.fr/modules/news/others pages :
http://www.site.fr/modules/news/index.php?storytopic=Xor
http://www.site.fr/modules/news/article.php?storyid=X
-
create a file : myfile.php
with this :
<?php
if ($_SERVER['REQUEST_URI'] == "/modules/news/")
{
$this->assign('top_page', '1');
}
?>
in your theme.html, add this ligne (under <body> tag)
<{include_php file="$xoops_rootpath/themes/my_theme/myfile.php"}>
then, I can use smarty like this, to display a block only on top page :
<{if $top_page == "1"}>
your code here
<{/if}>
hope this can help you !