gpt4 book ai didi

drupal - 如何将寻呼机放在页面的顶部和底部?

转载 作者:行者123 更新时间:2023-12-01 05:43:55 24 4
gpt4 key购买 nike

我知道我需要使用 theme_pager 函数来呈现代码:

http://api.drupal.org/api/function/theme_pager/6

我知道它被预渲染到 page.tpl.php 的 $content 中,如果我想主题化它,我只需要将 theme_pager 函数覆盖到 template.php 中。

我知道在 View 中我只需要使用变量 $pager,但我没有使用 View 。

我想知道的是我如何简单地调用 theme_pager 传递一个变量“items”。我在哪里可以找到寻呼机的“项目”?

编辑:

没有“项目”,寻呼机的内容全局传递给函数。

所以如果你想在你的页面顶部添加一个新的寻呼机,你只需要在 page.tpl.php 上调用“theme_pager”函数(或者你的,如果你覆盖了它):

<?php print $content_top; ?>             

<?php echo theme('pager', null, 1, 0, array(), 9); ?>

<div id="content-area">
<?php print $content; ?>
</div>

最佳答案

你不通过itemstheme_pager .

如果您传入相同的 ID:$element对于该功能,它应该可以与已添加的寻呼机一起正常工作。

关于drupal - 如何将寻呼机放在页面的顶部和底部?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3547892/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com