Active
Project:
Panelizer (obsolete)
Version:
7.x-3.x-dev
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
14 Nov 2014 at 01:50 UTC
Updated:
18 May 2018 at 06:41 UTC
Jump to comment: Most recent
Comments
Comment #1
morseCode commentedThis is how i ended up doing this in case someone else happens upon this post
Comment #2
morseCode commentedComment #3
eclipsegc commentedFor anyone else who finds this, here's the appropriate way to solve this:
Eclipse
Comment #4
merylmabin commented#1 mostly worked for me, except that I needed to change the last line:
page_manager_node_view_page( $node )["content"]["#markup"]
Comment #5
Würden commentedThis only renders the node with the node_view panel, not the panelized panel. So the suggested solutions are not really for panelizer, only panel nodes.
For the standard panels node layout I use a 1col layout but for the panelized layout for full content of a node type I use a different 2col layout, but using the suggested method it seems the whole process of rendering with panelizer is skipped, the node only comes out in the 1col version. Is there any way to actually render the node programmatically with a panelized layout applied?
Comment #6
Würden commentedThe only way I was able to achieve what I wanted, load the node with the correct panelized layout was to use file_get_contents from the node URL and from there get the raw HTML code and filter out header/footer.
This can't be the only working way of achieving this, it must be possible somehow to load a node as Panelizer does.
Comment #7
damienmckenna@CFE: What view mode are you using with Panelizer for the node you want to display?
Comment #8
Würden commented#7 I'm using the standard, "Full content" build mode. In page manager the Node template is activated and inside that panel is the pane "Node being viewed" content - which is usually rendered via panelizer on the frontend, however using the node_view function it seems to skip rendering with the layout I selected in panelizer. So my guess is that you need to use something more specific than the node_view() function.
Comment #9
andriy khomych commentedHi all, what about set up special view mode for render?Teaser for example.
Comment #10
steveoriolHello,
#1 or #3 worked for me, but I get an Array when I am connected with user 1 (with content is in ["content"]["#markup"]).
with this PHP Notice :
But for anonymous or normal users, "page_manager_node_view_page($node)" return directly the HTML content.
Why? , can I have the same results ?
Comment #11
damienmckenna@steveoriol: Maybe the Contextual module, or something else, is trying to add extra data to the output? What is the node being rendered? Maybe that system is expecting the output to be in a different structure, e.g. a string instead of an array?
Comment #12
monymirza