Hi.

I'm trying to hack in the node title and body into the email that is sent out with the forward module.

despite including:

$node = node_load($nid);

and

$body .= $node->title;
$body .= $node->body;

into the message nothing is showing up when the email is sent.

Can anyone let me know how to do this?

erik.

Comments

nevets’s picture

You need to change the call to node_load() to

 $node = node_load(array('nid' => $nid));
erikhopp’s picture

i am trying to replace the

in the $node->body with a newline in the email.

$nodebody = str_replace('<p>', '\n', $nodebody);

that just puts a "\n" as text in the email.

any way to put a new line in?

thanks!

erik

http://mediamutiny.org | http://quilted.org

erikhopp’s picture

this works:

$nodebody = str_replace('<p>', "\n", $nodebody);

notice the double quotes.

http://mediamutiny.org | http://quilted.org