I am using drupal7. I am creating custom article content type. Standart node type supports only two view modes teaser and full view modes.
function mymodule_view($node, $view_mode){if($view_mode =='full'){
$node->content['#theme']='my_full_node_view_theme';}if($view_mode =='teaser'){
$node->content['#theme']='my_teaser_node_view_theme';}return $node;}
I have to add some other view options for this node type like :
- small_box
- small_box_with_user_pic
- big_box
and want to render node with code like this
$node = node_load($my_nid);
$output = drupal_render(node_view($node,'big_box'));
thanks for your attention. Any help appreciated.