I have added a view to a views area (footer) programmatically using the following in hook_views_pre_view():

$item = array(
  'id' => 'area2',
  'table' => 'views',
  'field' => 'view',
  'relationship' => 'none',
  'group_type' => 'group',
  'admin_label' => '',
  'empty' => NULL,
  'view_to_insert' => 'footer_view:page_1',
  'inherit_arguments' => false,
  'plugin_id' => 'view',

$view->setHandler($display_id, 'footer', 'area2', $item);

I do not want to use the contextual arguments from the view I have added this to, but I do want to set the footer_view arguments in code. Any ideas?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.