简体   繁体   中英

Get a List of Available Drupal Views

I'd like to set up a configuration page for my Drupal module that contains a dropdown where the user selects one of the available views. Is there an easy way to obtain a list of all available views on the system? All I need is an array of all the views' names.

尝试使用views_all_get_views函数 ...这将返回一个视图数组,按名称索引,因此您可以围绕结果包装array_keys()以获取名称。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM