在Drupal中创建上下文视图,然后根据NID(节点ID)显示在Panel中 [英] Create a Context View in Drupal and then display in Panel based on NID (node id)

查看:124
本文介绍了在Drupal中创建上下文视图,然后根据NID(节点ID)显示在Panel中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个快速的问题。我相信这很容易做,但我错过了一些东西。



如何创建所有内容/节点类型的视图上下文。那么我想根据NID / Node ID在Panel 3中显示我的节点?这是正确的方法吗?



背景:



有很多教师是内容类型。所有老师都有一个页面,例如
www.example.com/all-teachers。如果用户从该页面点击特定教师,则应该将其引用到:



www.example.com/teacher-name - 此页面应显示内容这位老师。



请问我的问题是否不清楚,非常感谢您的帮助。






谢谢你的回复。



面板3部分只有一个自定义布局页面。我使用960grid显示内容。我想根据NODE ID在面板中显示动态内容。



这样做的方法是创建一个View并传递一个将被称为节点ID的参数。然后在面板3中,您可以创建上下文(视图)。这允许您将节点中的字段放在单独的内容窗格上。



显示的URL将基于节点ID。它基本上就像为许多不同的教师细节创建1个模板。我不知道如何在技术术语上解释,但我希望你能得到这个想法。



谢谢。

解决方案

我不明白为什么你需要面板。不能看到只是把每个老师连接到它的节点?如果您想要控制教师节点的显示方式,为什么不使用展示套件等。


I have a quick question. I am sure it is easy to do but I am missing something.

How do I create a View Context of All Content/Node Types. Then I want to display my nodes in Panel 3 based on NID/Node ID? Is this the right way to go?

Background:

There are many teachers as Content Types. There is a page for all teachers eg www.example.com/all-teachers. If a user clicks on "a particular teacher" from this page they should be taken to:

www.example.com/teacher-name - this page should display contents from "this teacher".

Please ask if my question is not clear and thank you so much for your help.


Thank you for your reply.

The Panel 3 part is only to have a custom layout page. I am using 960grid to display the content. I want to display dynamic content in the panel based on NODE ID.

The way to do this is to create a View and pass an argument which will be Node ID. Then in Panel 3 you can create the Context (View). This allows you to put fields from the node on seperate content panes.

The URL displayed will be based on the Node ID. Its basically like creating 1 template for many different teacher details. I am not sure how to explain it in technical term but I hope you get the idea.

Thanks.

解决方案

I don't understand why you need panels at all. Can't the view just link each teacher to it's node? If you want to control how a teacher node is displayed why not use something like Display Suite.

这篇关于在Drupal中创建上下文视图,然后根据NID(节点ID)显示在Panel中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆