use a custom view mode in node.tpl With Display Suite we can make custom view modes other then Teaser to use through out the site (in views for example). This is working fine and very nice!

However, using the custom view in a .tpl file does not work (where $teaser is confirmed to work).

Notice: Undefined variable: custom_view_mode_one in include() (line 92 of /home/dev/drupal-7.x/sites/.../node--custom-content-type.tpl.php). =&gt;


do i need to register this in template.php even though it is already registered on the page and usable everywhere else?
$teaser is being passed in from template_preprocess_node().  DS just makes the view mode via a hook_entity_info; it doesn't wire it into the themeing system.  You need to do something like this:

function MYTHEME_preprocess_node(&amp;$variables) {
  $variables['custom_view_mode_one']
    = $variables['custom_view_mode_one'] == 'custom_view_mode_one';
}


You could also be smart by using a entity_get_info('node'), and get all of the view modes, and set similar variables.

Note that you should already have a variable called view_mode available in your template, too.