Closed (fixed)
Project:
Node Hierarchy
Version:
5.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
30 Mar 2008 at 22:57 UTC
Updated:
16 Aug 2010 at 02:46 UTC
When I use the nodehiearchy_children_teaser view on a parent, the children's teasers show up above the parent's body text. In all cases, I want the children's teasers to show up below b/c the parent content body provides a sort of introduction. Interestingly, if I select nodehiearchy_children_list, the list does show up below the parent's body text.
What do I need to modify to force nodehierarchy_children_teasers to show up below the parent content body?
Comments
Comment #1
dgorton commentedThis is probably something in your theme layer... what theme are you using?
Oodles (almost all) of our sites use NH to show child views below a parents 'body' content like you are describing. Accordingly, the code in our templates often is a variation on something like this:
Something like that should do it...
Comment #2
mr_dimsum commenteddgorton,
Do you apply this to the theme so you don't have to manually select each Node Hierarchy list in the settings?
Comment #3
ronan commentedNodehierarchy Views embeds the children with a weight of 10, this should make it appear below all of your CCK fields etc. Which view you choose should not affect that weight, so I'm really not sure what's going on there. The body field is fixed at weight 0 which is clearly less than 10... very odd
Comment #4
dgorton commentedYes and no. That snippet of code is in the node-CONTENT-TYPE-tpl.php file. (I just looked at one and noted that the file had '#value' instead of #view - which strikes me as odd at the moment, but anyways...)
Regardless, my answer is probably to be ignored anyways as Ronan is correct in pointing out that the view is the view - and it ought to be landing in the same place every time. I'm not sure how that's being done, actually - it would take some pretty deliberate theming to move views around based on the type of view being shown... Did you create this theme? What does the applicable theme file have in it?
Comment #5
pdx_cav commentedI'm using a custom theme that is based off of the garland theme. I have searched through node.tpl.php and page.tpl.php & node.tpl.php so far haven't found anything that looks like the right place to add this in. Any suggestions on where else to look?
Thanks.
Comment #6
dgorton commentedCan you paste in your tpl code? Is this happening for every content type? We're going to be looking for the code from one of the .tpl files that's being called in this oddball case...
Comment #7
dgorton commentedComment #8
darrellduane commentedI am having this problem in version 6 after migrating a site from a different server and upgrading to the latest version of Node Hierarchy. Any clues how I can put the node image header above the views? Changing the order_by value to be heavy didn't fix it.
Comment #9
darrellduane commentedOk, I found that I could edit the nodehierarchy_views.module and change the weight value from 10 to 999 and this fixes my problem, but I can't find where to set the weight of the body field so that I don't have to make this change. Right now, the weight of my node's body is showing up as 51. Does anyone know where I can change this or edit it in the database? I see ronan's comment above that says that the body field's weight is fixed at 0, so I'm wondering now if this install of drupal has had this field edited in the code or if this value can now be set someplace else. The title weight is showing up as 47.
Comment #10
dgorton commentedClosing as part of ticket/queue cleanup. The 5.x support issue has been dormant for 2+ years. If there's still a 6.x issue, please open an new ticket.