[% sections.title = dw.ml( ".title.$type" ) %] [%- CALL dw.active_resource_group( "foundation" ) -%]

<< [% dw.ml( '.backlink', { sitename => site.nameshort } ) %]

[% IF randomu %]

[% dw.ml( ".intro.$type", { aopts => "href='${site.shoproot}/randomgift?type=$type'", aopts2 => "href='${site.shoproot}/account?for=random'" } ) %]

[% dw.ml('.label.username') %] [% randomu.ljuser_display %]
[% dw.ml('.label.createdate') %] [% mysql_time( randomu.timecreate ) %]
[% dw.ml('.label.lastupdated') %] [% mysql_time( randomu.timeupdate ).substr( 0, 10 ) %]
[% dw.ml('.label.numentries') %] [% randomu.number_of_posts %]
[% IF type == 'P' %] [% dw.ml('.label.numcomments') %] [% randomu.num_comments_posted %]
[% dw.ml('.label.numcommunities') %] [% randomu.member_of_userids.size ? randomu.member_of_userids.size : 0 %]
[% ELSE %] [% dw.ml('.label.numcomments') %] [% randomu.num_comments_received %]
[% dw.ml('.label.nummembers') %] [% randomu.member_userids.size %]
[% END %]

[% form.hidden( name = 'username', value = randomu.user ) %] [% form.submit( value = dw.ml( '.form.submit', { username => randomu.user } ) ) %]

[% dw.ml( ".form.getanother.$type") %]   [% dw.ml( ".form.switchtype.$type") %]


[% ELSE %]

[% dw.ml( ".nousers.$type") %]

  [% dw.ml( ".form.switchtype.$type") %] [% END %]

<< [% dw.ml( '.backlink', { sitename => site.nameshort } ) %]