Announcement

Collapse
No announcement yet.

Display username and userid in custom template?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Display username and userid in custom template?

    Hello, I just created a custom template called "pulso_gallery" with this content:
    HTML Code:
    <a href="/profile/showgallery.php?cat=500&ppuser=$userinfo[userid]"><img src="$stylevar[imgdir_misc]/pulso_gallery_icon.gif" alt="Ver Galer&iacute;a de $userinfo[username]" border="0"></a>
    Created a plug-in to call the custom template under: postbit_display_start
    PHP Code:
    eval('$view_pulso_gallery = "' fetch_template('pulso_gallery') . '";'); 
    And added it below the IM icons on the postbit template.

    It works fine, with the only problem that the variables $userinfo[username] and $userinfo[userid] do not work. They do not appear on the template. How can I call the user id and username on that custom template?

    Thanks

  • #2
    Use $bbuserinfo[username] and $bbuserinfo['userid'] in templates
    Minatica.be - Belgian/Dutch computer and technology site
    DownloadsII - Add a downloads database to your vB 4

    Comment


    • #3
      Originally posted by RS_Jelle
      Use $bbuserinfo[username] and $bbuserinfo['userid'] in templates
      Hello... I just tried
      Code:
      $bbuserinfo[username] and $bbuserinfo[userid]
      And what I get is my userid and username.

      What I need is to display the userid from that postbit. Just like the IM icons pass the userid for getting their personal details on IM, I need to display the userid and username from the user of that post. Thanks...

      Comment


      • #4
        Sorry, my mistake

        Try using $post[username] and $post[userid]
        Minatica.be - Belgian/Dutch computer and technology site
        DownloadsII - Add a downloads database to your vB 4

        Comment


        • #5
          Originally posted by RS_Jelle
          Sorry, my mistake

          Try using $post[username] and $post[userid]
          great... now worked... thanks!

          Comment

          widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
          Working...
          X