You just need to get the nid of the main node into the creation of the
subordinate node typoes. How about using a query string to specify the
parent, like<br>
<br>
node/add/B?mainnode=(nid of A)<br>
<br>
or maybe<br>
<br>
node/add/B/(nid of A)<br>
<br>Populate the new field in hook_form(). You can even choose to show an input control for the field if it's not specified<br>
<br><div><span class="gmail_quote">On 11/16/05, <b class="gmail_sendername">Sergio</b> <<a href="mailto:lsmoura@gmail.com">lsmoura@gmail.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hello, folks,<br> I'm in need of a little help...<br> I have a module with 3 types of node. Node A, B and C.<br>
I am trying to do something like A is the main node and B & C
references A. So that, when I show the node A (teaser or full node), I
get some informations about nodes type B and C that makes reference to
A.
<br> Also, I want to node types B and C have a reference to the parent (A).<br>
When the user inserts the data, it must be transparent to him as who
the parent is (like there is a link on node type A that allows the user
to create type B or C and the node creation page will not ask the user
who the parent is). The only creation method shoud be like this for
nodes B and C (there should not have a link on the node creation list.
Just for type A)
<br><br> I took a look at the project module, but I couldn't get much out of it...<br> Any help is appreciated...<br><br>Thanks,<br>- Luis Sergio Moura<br>
</blockquote></div><br>