When I go to user titles admin and select a node type to count, I get these warnings:

    * warning: Invalid argument supplied for foreach() in /mysite.com/sites/all/modules/user_titles/user_titles.module on line 202.
    * warning: Invalid argument supplied for foreach() in /mysite.com/sites/all/modules/user_titles/user_titles.module on line 224.

I followed the readme and added the code to my comment & node .tpl's.

I use Drupal 6.8, user stats, and Advanced Forum modules. Everything works fine except UT.

CommentFileSizeAuthor
#2 user_titles_warnings.patch2.64 KBagileware

Comments

agileware’s picture

Status: Active » Fixed

Hi ssace,

Thanks for picking this bug up. It happens regardless of drupal version or other modules when ever you save the settings while there are no user titles.

I have now fixed the bug in 6.x-1.x-dev, which should be up in the next half day and I will make a new release with the fix soon.

agileware’s picture

StatusFileSize
new2.64 KB

If you don't like using dev versions you can use this patch on 6.x-1.0-beta1 until the next release is done. It won't be too far away though.

agileware’s picture

There is now a new 6.x-1.0-beta2 release that has this fixed.

It also has the new functionality that was recently added to the D5 version:
- Hookable points system
- Removed javascript from settings
- Can now add an image to a user title

snsace’s picture

Thanks for this fix, no warnings now.

However, I am having a problem with title images not showing up in comment posts. The only thing that
shows is the title text for the images I uploaded. I put this in my comments.tpl file:

<?php if ($user_title): ?>
     <div class="user-title"><?php print $user_title; ?></div>
<?php endif; ?>

I am using advanced forum but I don't think it's a problem with that. I am also using user_badges module...do
you think it could be a problem with using these badges & titles together? User badge images show up fine.
One difference is in the code to make the user badges images show up is different that with user titles. I use
this to make user badges work:

<?php print user_badges_for_uid($comment->uid); ?>

snsace’s picture

Just checking again...any ideas why title images don't show in forum posts? The title name shows, but not the image.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.