function views_content_context_view_get_child

1 string reference to 'views_content_context_view_get_child'
view.inc in views_content/plugins/contexts/view.inc
Plugin to provide a node context. A node context is a node wrapped in a context object that can be utilized by anything that accepts contexts.

File

views_content/plugins/contexts/view.inc, line 31

Code

function views_content_context_view_get_child($plugin, $parent, $child) {
    list($name, $id) = explode('-', $child, 2);
    $view = views_get_view($name);
    if (!$view) {
        return;
    }
    $view->set_display($id);
    if ($view->current_display != $id) {
        return;
    }
    $info = _views_content_get_context_from_display($view, $id, $parent, FALSE);
    if ($info) {
        return $info;
    }
    return;
}