![]() |
Member number in profile
Is there any way to add a the member number of the user to their profile. Say a member signs up and is 301 can you add that somewhere in his profile?
|
You would need to do it manually, like in a template edit. Depending on which template you add it to, it's probably either {vb:raw userinfo.userid} or {vb:raw prepared.userid}
|
I tried this and it don't work. Any ideas.
<vb:if condition="$post['membernumber']"><dt>{vb:rawphrase member_number}</dt> <dd>{vb:raw post.userid}</dd></vb:if> |
In profile you need to use prepared.userid, not post.userid (which is for postbit).
|
So like this? I tried it and it don't work.
<vb:if condition="$post['membernumber']"><dt>{vb:rawphrase member_number}</dt> <dd>{vb:raw prepared.userid}</dd></vb:if> |
As Cellarius said, $post is not a valid variable there. What is $post[membernumber] supposed to be? Don't you mean something more like $prepared['userid']?
|
I think I'm a tard, lol. So how would I write that to get it to worK?
|
Maybe something like:
<vb:if condition="$prepared['userid']"><dt>{vb:rawphrase member_number}</dt> <dd>{vb:raw prepared.userid}</dd></vb:if> Have you even tried it without the condition to see if that part is correct? |
I just tried it and it didn't work. Pulling my hair out, lol.
|
Try...
Code:
<vb:if condition="$prepared['userid']"><dt>{vb:rawphrase member_number}</dt> <dd>{vb:raw userinfo.userid}</dd></vb:if> Edit: Yeap and to confirm, it's what Lynne mentioned above in post #2. |
So would the whole code look like this? Or am I missing something. I tried it and nothing. I'm still learning, lol. Thanks for all the help everyone.
{vb:raw prepared.userid}<vb:if condition="$prepared['userid']"><dt>{vb:rawphrase member_number}</dt> <dd>{vb:raw userinfo.userid}</dd></vb:if> |
As I asked before..
Have you even tried it without the condition to see if that part is correct? |
Also: Where exactly do you put that code?
|
Quote:
Quote:
|
So you're in postbit after all? :confused:
In your first post, you wrote you would want to show it in the member's profile! As has been pointed out, the code needs to be different for profile (the memper's page you get taken to if you click on a username) and postbit (the information field on top or on the left of every post in threadview). Try this: Code:
<dt>{vb:rawphrase member_number}</dt> <dd>{vb:raw post.userid}</dd> If you ask questions like that, please provide as much information on what you want to achieve where - makes it a lot easier to help :) |
I want it underneath the avatar. Like where it says join date, real name and so on. Sorry again for the confusion.
|
Have you tried the code I provided?
|
Awesome! Thank you for your time. If you need anything just ask!
|
All times are GMT. The time now is 08:08 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|