gpt4 book ai didi

php - 如何在 drupal 7.x 中获取用户角色?

转载 作者:行者123 更新时间:2023-12-02 05:27:14 35 4
gpt4 key购买 nike

我想获取用户角色就像使用这个获取节点类型一样

node_type_get_types();

有没有办法使用这样的函数来获取用户角色?

最佳答案

参见 user_roles()提供所有角色列表的功能,或者您可以选择根据特定条件进行过滤(我链接到的文档页面上有更多详细信息)。

关于php - 如何在 drupal 7.x 中获取用户角色?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8327126/

35 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com