XF 2.3 Displaying Custom user fields data under user profile photo

ActorMike

Well-known member
IN 2.2 I added the code below to add their car's model year under the users profile in the forums. No longer works in 2.3 and gives a parse error. How can custom user data added in 2.3 under the users profile handle where it says "Well-Known member" for example?

Code:
 .message-userExtras
 {
 display: block !important;
 }
 
Last edited:
If I understand correctly the model year is from a custom user field isn't it? In 2.2 and again in 2.3, to display it in the postbit, you just need to check the box in the style properties... ACP >> Appearance >> Style properties >> Messages

1724141294330.webp

Or did I miss something in your question?
Side question, were you using an add-on related to this, an add-on that you uninstalled when upgrading to 2.3?
 
//Display Model Year under user handle in bold is not a valid comment in CSS - remove that or use /* Display Model Year under user handle in bold */ which is a valid CSS comment.

 
//Display Model Year under user handle in bold is not a valid comment in CSS -
This is true, but this is inside the extra.less file and that is for comments and ignores those lines. In fact, I put these // in front of these lines that worked in 2.2 and no longer work in 2.3 and it ignores them now and there is no error generated.

To clarify, this extra.less code all words in 2.2.
 
To clarify, this extra.less code all words in 2.2.
That doesn't necessarily mean it will work in 2.3.

Just one example:

The stack trace indicates the parser chokes on the comment line, maybe in conjunction with other definitions - but that is difficult to diagnose without seeing the full LESS code.
 
//Display Model Year under user handle in bold is not a valid comment in CSS - remove that or use /* Display Model Year under user handle in bold */ which is a valid CSS comment.


It's a valid LESS comment: https://lesscss.org/#comments

app_nav.less
1724173572712.webp


Do you have CSS above/below the code you posted? Could be something else going on (even though the error is pointing to that)
 
Oh my, this went down the rabbit hole real quick. LOL. Let me rephrase the question.

In XF 2.3, how can I display the data from a Custom user field under the profile photo of the member?

It stopped working in 2.3.
 
Last edited:
Oh my, this went down the rabbit hole real quick. LOL. Let me rephrase the question.

In XF 2.3, how can I display the data from a Custom user field under the profile photo of the member?

It stopped working in 2.3.
The original reply is the correct answer. You need to make sure that this is also checked (I'm assuming it's a custom user field).

Users -> Custom user fields -> Select field -> General Options -> Viewable in message user info
 
Got it! The only problem with this new methods is that it shows the entire name of the field "Thunderbird Year" and that's too long for the forum and takes two lines, and it says we cannot change that customer user field to something else like "Tbird"

Screenshot 2024-08-20 192341.webp

EDIT: made it 5px wider and it fits.
 
Last edited:
Back
Top Bottom