Commit c55570f5 authored by git's avatar git Committed by codycraven
Browse files

Issue #1754636 by vidorado: Allow using associated content View title configuration.

parent 9851575c
Taxonomy Display 7.x-1.x, YYYY-MM-DD
------------------------------------
Issue #1754636 by vidorado: Allow using associated content View title
configuration.
Taxonomy Display 7.x-1.1, 2012-10-29
------------------------------------
......
......@@ -55,6 +55,12 @@ class TaxonomyDisplayAssociatedDisplayHandlerViews extends TaxonomyDisplayAssoci
'#markup' => $output,
);
}
// Set page title from view's title if desired, and if it has a title set
if ($options['use_view_title'] && $view->build_info['title']){
drupal_set_title(strtr($view->build_info['title'], $view->build_info['substitutions']), PASS_THROUGH);
}
}
return $build;
......@@ -121,6 +127,17 @@ class TaxonomyDisplayAssociatedDisplayHandlerViews extends TaxonomyDisplayAssoci
'#title' => t("View's display"),
'#type' => 'select',
);
$form['use_view_title'] = array(
'#default_value' => isset($options['use_view_title']) ? $options['use_view_title'] : 0,
'#return_value' => 1,
'#description' => t('If checked, the page title will be inherited from the view\'s display page title, instead of using the term name.'),
'#prefix' => '<div id="replace-td-views-use_view_title-field">',
'#suffix' => '</div>',
'#title' => t("Set page title the same as view display title"),
'#type' => 'checkbox',
);
}
/**
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment