如何在位置类型视图上使用 cck 字段?

发布于 2024-09-13 18:18:49 字数 107 浏览 2 评论 0原文

我有一个 LOCATION 类型的视图。我的问题是,当我尝试添加 cck 字段时,类型下拉列表中不提供“内容”类型。

我也尝试添加关系,但内容也不存在。

有什么想法吗?

I have a view of type LOCATION. My problem is that when I try to add a cck field the type "content" is not available on the type dropdown.

I also tried to add a relationship but the content is not there also.

Any ideas ?

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

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

发布评论

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

评论(2

黑白记忆 2024-09-20 18:18:49

以下是我为解决问题所做的操作

1 - 我添加了 视图自定义字段 模块

2 - 添加了一个新的字段(PHP 自定义字段),我创建了一个 SQL 命令来搜索数据库上所需的内容。

我希望它有帮助。

Here is what I did to solve the problem

1 - I added Views Custom Field Module

2 - Added a new field (PHP Custom Field) and I created a SQL command to search the content that I needed on the database.

I hope it helps.

定格我的天空 2024-09-20 18:18:49

如果您的视图类型是位置,您将无法从内容类型获取自定义字段。

根据您正在做的事情,您可能想要做的是:

  1. 创建一个名为“my_location”的新内容类型
  2. 添加位置模块([位置模块][1])
  3. 打开位置模块,您将使用节点位置。
  4. 创建一些内容,不要添加在映射方面有很多问题的位置 cck 字段,而不是我们的节点位置。

  5. 将自定义字段添加到您的内容类型“my_location”

- 现在,内容类型“ym_location”充当带有 cck 字段的单个位置(如果您需要连接)将此内容添加到网站上的其他内容,您可以使用 [Node Referrer][2]

  1. 最后查看节点而不是位置,然后将“内容类型”过滤为“my_location”,这将允许您从节点中提取位置字段并所有 cck 字段。

希望这有帮助。我在一个项目中使用了这种逻辑,我们需要每个位置的更多信息,但我们仍然想绘制位置地图。

If your view type is location you are not going to be able to get the custom fields from your content type.

depending on what you are doing what you may want to do is:

  1. create a new content type called 'my_location'
  2. add location module ([location module][1])
  3. turn on location module, you are going to use the node location.
  4. create some content, DONT add location cck field that have lots of issues with mapping instead us the node location.

  5. add custom field to your content type 'my_location'

-- now the content type 'ym_location' acts as a single location with cck fields, if you need to connect this to other content on the site you can use the [Node Referrer][2]

  1. finally make a view of nodes NOT locations, then filer 'content type' to 'my_location' this will allow you to pull the location fields from the node and all the cck fields.

Hope this helps. I used this logic on a project where we needed more information on each location but we still wanted to map the locations.

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