Show image_pager in node.
| Project: | Image Pager |
| Version: | 5.x-1.0 |
| Component: | Miscellaneous |
| Category: | support request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
I have seen the two other threads asking for support to have the pager work in the node content.
I think it is possible to display within a node by using a node-type.tpl file to print the image_pager.
I added the following to my node-news.tpl (my cck type is called news).
I put this at the start…
<?php drupal_add_js(drupal_get_path('module', 'image_pager'). '/image_pager.js'); ?>
<?php drupal_add_css(drupal_get_path('module', 'image_pager'). '/image_pager.css'); ?>…and added this where I wanted the pager to appear within the node (above my content, but below the node title).
<?php print theme_image_pager_block();?>When the node is displayed the node-type.tpl is processed and the pager works :)
I think this could all be a feature of the module, allowing users to specify which node types to display the pager on via an admin page. I also think hook_node_alter() could be used to make it less necessary to hand code hacks like this.
