I need to redirect certain content types to other nodes.
As a proof of concept I've got this working with a drupal_goto
at the top of node--[type].tp开发者_StackOverflow社区l.php
This works great, but is probably the least optimized place to put it.
Would phptemplate_preprocess_node
be too early?
What about hook_nodeapi, $op='view'
?
Where's the smartest place to put a drupal_goto?
hook_nodeapi
's view
hook is where I'd put it, yeah. It's going to be one of the first spots you'll have the $node
variable to inspect for the node types you're redirecting.
精彩评论