Gossamer Forum
Quote Reply
I called this function in my script

However the reference it returns seems to be missing some stuff.

Everything tallies with what I get in that big "Everything" loop in category_list.html
except for the following 2 keys
{'forum_new'} and {'forum_permission'}

The $USER reference is initialised correctly.

Do I need to call another function to get those keys in?

Quote Reply
Re: [dauhee] GForum::Forum::tpl_list In reply to
Is this in a script, or in a template?

In Perl code (if in a template, you could put this inside a sub { ... } global) you should do the following:


my $tpl_list = GForum::Forum::tpl_list('hide_user');
GForum::Category::_calc_new($tpl_list->{tpl_list}) if $SESSION;
_calc_new is what sets forum_new - it doesn't happen automatically because calculating the new posts is not such a simple task. forum_permission is, however, set automatically and so it should be available to you.

Jason Rhinelander
Gossamer Threads
Quote Reply
Re: [jagerman] GForum::Forum::tpl_list In reply to
I am using it in a script.

Thanks for your help. It is working fine now. Smile