Problem is located in advanced_blog.module token implementation.
It duplicates the same token for two different purposes.
Replace one token as follows:
Use:
if ($type == 'user') {
$user = $object;
$results = db_query("SELECT title, description, format FROM {advanced_blog} WHERE uid = %d", $user->uid);
$advanced_blog = db_fetch_object($results);
$tokens['user-blog-title'] = $advanced_blog->title;
}
Instead original
if ($type == 'user') {
$user = $object;
$results = db_query("SELECT title, description, format FROM {advanced_blog} WHERE uid = %d", $user->uid);
$advanced_blog = db_fetch_object($results);
$tokens['blog-title'] = $advanced_blog->title;
}
and use
if ($type == 'user' || $type == 'all') {
$tokens['user']['user-blog-title'] = t('User\'s Blog Title from advanced_blog module.');
}
instead of original
if ($type == 'user' || $type == 'all') {
$tokens['user']['blog-title'] = t('Blog Title from advanced_blog module.');
}
I have update the token implementation, taking ofercorn's code snippet into account.
Please test if the latest HEAD version of the module fixes the reported problems.
Comments
Comment #1
mariano.barcia commentedsame problem here, with the latest versions
Comment #2
ofercorn commentedProblem is located in advanced_blog.module token implementation.
It duplicates the same token for two different purposes.
Replace one token as follows:
Use:
Instead original
and use
instead of original
OTH: code has numerous other issues :-(
Comment #3
dries arnoldsSame issue here...
Comment #4
browlands commentedditto, +1
Comment #5
svendecabooterI have update the token implementation, taking ofercorn's code snippet into account.
Please test if the latest HEAD version of the module fixes the reported problems.