<!doctype html public "-//W3C//DTD W3 HTML//EN">
<html><head><style type="text/css"><!--
blockquote, dl, ul, ol, li { padding-top: 0 ; padding-bottom: 0 }
--></style><title>Re: [development] starting...</title></head><body>
<div>Hello, Willians. Welcome to Drupal. The code for the annotation
module can be downloaded here</div>
<div><br></div>
<div
>http://www.drupalbook.com/files/7559ch02%20-%20Your%20First%20Module<span
></span>.zip</div>
<div><br></div>
<div>in case you want to compare it to the code you are using. The
code works by retrieving a note from the database and assigning the
value to the node object. The node is then passed to the form
function. It looks like you are passing only the annotation property
and not the entire node. Your code:</div>
<div><br></div>
<div>...'#value' => drupal_get_form('annotate_entry_form',
$node->annotation),</div>
<div><br></div>
<div>what it should be:</div>
<div><br></div>
<div>...'#value' => drupal_get_form('annotate_entry_form',
$node),</div>
<div><br></div>
<div>This kind of question is best asked in the drupal.org support
forums rather than on the development list.</div>
<div><br></div>
<div>http://drupal.org/forum/18</div>
<div><br></div>
<div>John</div>
<div><br></div>
<blockquote type="cite" cite> Hello, I'm Willians, living in
Brazil and do not know English law, then not repair the errors. :D<br>
I starting the develop for drupal, know a little of PHP, mysql.
I am reading the book Pro Drupal Development, and the example of the
book "chapter 2", I am not understanding the code right.<br>
More specifically, the function where return the datas. that is
annotate_nodeapi(&$node, $op, $teaser, $page), when return the
result of the database, this
code: <br>
$node->annotation
= db_result($result);<br>
No is showing, the result in screnn, should be :<br>
<br>
$node->content['annotation_form'] =
array(</blockquote>
<blockquote type="cite" cite>
'#value' => drupal_get_form('annotate_entry_form',
$node->annotation),<br>
'#weight' => 10<br>
);<br>
<br>
Someone knows where my erros ??<br>
<br>
Thank you, all... :D<br>
<br>
willians<br>
<br>
--<br>
<a
href="http://www.ecommunita.com/">http://www.ecommunita.com/</a></blockquote>
<div><br></div>
</body>
</html>