*** token_node.inc.orig 2008-02-07 15:04:55.000000000 +0200 --- token_node.inc 2008-02-07 15:24:55.000000000 +0200 *************** *** 16,21 **** --- 16,28 ---- $values['title'] = check_plain($node->title); $values['title-raw'] = $node->title; + $values['teaser'] = check_plain(preg_replace(array('/\<\/p\>/','/\n/'),' ',$node->teaser)); + $values['body'] = check_plain(preg_replace(array('/\<\/p\>/','/\n/'),' ',$node->body)); + $values['body-50'] = substr(check_plain(preg_replace(array('/\<\/p\>/','/\n/'),' ',$node->body)),0,50); + $values['body-100'] = substr(check_plain(preg_replace(array('/\<\/p\>/','/\n/'),' ',$node->body)),0,100); + $values['body-200'] = substr(check_plain(preg_replace(array('/\<\/p\>/','/\n/'),' ',$node->body)),0,200); + $values['body-400'] = substr(check_plain(preg_replace(array('/\<\/p\>/','/\n/'),' ',$node->body)),0,400); + $values['author-uid'] = $node->uid; $values['author-name'] = check_plain($node->name); $values['author-name-raw'] = $node->name; *************** *** 154,159 **** --- 161,173 ---- $tokens['node']['title'] = t('Node title'); $tokens['node']['title-raw'] = t('Unfiltered node title. WARNING - raw user input.'); + $tokens['node']['teaser'] = t('Node teaser'); + $tokens['node']['body'] = t('Node body'); + $tokens['node']['body-50'] = t('First 100 characters of a body'); + $tokens['node']['body-100'] = t('First 100 characters of a body'); + $tokens['node']['body-200'] = t('First 200 characters of a body'); + $tokens['node']['body-400'] = t('First 400 characters of a body'); + $tokens['node']['author-uid'] = t("Node author's user id"); $tokens['node']['author-name'] = t("Node author's user name"); $tokens['node']['author-name-raw'] = t("Node author's user name. WARNING - raw user input.");