Skip to content

Instantly share code, notes, and snippets.

@bratsun
Last active December 26, 2015 20:58
Show Gist options
  • Save bratsun/7212278 to your computer and use it in GitHub Desktop.
Save bratsun/7212278 to your computer and use it in GitHub Desktop.
Embed view with args
$view = views_get_view('opengraph');
$display_id = 'default';
$view->set_display($display_id);
//$view->set_arguments(array($element['#object']->nid));
$view->execute();
//print dpr($view->result);
print $view->result[0]->node_title;
views_embed_view('markers','block_1', implode('+',$args));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment