drupal中的分层选择模块问题

发布于 2024-10-05 08:28:30 字数 142 浏览 2 评论 0原文

我正在使用 Drupal 中的“分层选择”模块来创建 2 个州和城市的下拉列表,并通过更改州的方式将城市与州连接起来,城市列表也会发生变化。(它位于 CCK 和分类内容旁边模块)

问题是,通过选择新内容的州和城市,仅显示城市。但我需要两者,州-城市组合。

i am using 'Hierarchical select' module in Drupal to create 2 drop down of States and cities and connecting the city ones to state in a way by changing the state,the list of cities changes too.(it is beside of CCK and taxonomy content module)

The problem is that by selecting the state and city for a new content,just the city shown.but i need both of them,State - city combination.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

太阳公公是暖光 2024-10-12 08:28:30

分层选择是词汇分层结构的 UI 表示,通常显示在平面列表中。

从单个词汇表(如果禁用多项选择)中,您只能选择一个术语。选择叶子不会征募父代。

使用 taxonomy_get_parents()taxonomy_get_parents_all() 函数。

Hierarchical select is UI representation of hierarchical structure of vocabulary that is normally shown in a flat list.

From a single vocabulary (if multi select is disabled) you can select only one term. Selecting a leaf would not enlist parent tids.

Use taxonomy_get_parents() or taxonomy_get_parents_all() functions.

故事未完 2024-10-12 08:28:30

如果您在一个词汇表中拥有所有数据,并且城市是州的子级,那么一旦您选择了一个城市,它应该显示 State >>>节点上的城市。如果您使用 $terms 显示它们;那么它应该以这种方式显示。

If you have all that data inside of one vocabulary and cities are children of states, once you select a city, it should display State >> City on the node. if you're displaying them with $terms; then it should display in such fashion.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文