I have views block display that display full nodes that has reference same node. In block display one node (current uid) is displayed and in attachement all other nodes are displayed. In node template i have code to add new node form so each view result has form created by 'node_add'.

Strange part is that first result in attachement will have node form distorted (missing form elements). If I change attachement sort order other node becomes first result and form is distorted same way (node that had distorted form before is ok now). If I dont use attachements, all is OK.

Marking this as minor because there are workaround, but maybe this can be helpful to find some bigger bug :) Thanks.

Comments

dawehner’s picture

How do you generate the node form?

henrijs.seso’s picture

first i tried with adding region to node template and putting block with node_form inside it but later i tried also simply putting this in template.php

<?php
function starruner_preprocess_node(&$vars, $hook) {
module_load_include('inc', 'node', 'node.pages');
$vars['review_form'] = node_add('review');
}
?>

and printing $review_form in node template file.

Anyway, there is all kinds of wired sht going on, ill get back with more info when i win this beast.

dawehner’s picture

views does not do a hook_form_alter for the node form, so views cannot cause the problem :)

esmerel’s picture

Status: Active » Closed (fixed)

not a views issue.