Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
私は hook_views_query_alter() でいくつかの作業を行っており、そこから参照によって $views および $query オブジェクトにアクセスできます。
クエリを変更していますが、この表示のタイトルを変更するために同じ場所に保持したいロジックが少しあります (ブロックです)。
私の表示オブジェクトはこれです:$view->display[$view->current_display]
$view->display[$view->current_display]
そこから表示タイトルを変更する方法がわかりません。
build_info から変更できるはずです。
$view->build_info['title'] = "New title";