Skip to Content Skip to Menu

🕒 Save Time and Effort with CB Editor Assistant: Effortlessly create and refine content in Joomla 3, 4, & 5.
🎁 Limited Offer: Enjoy a 5-day FREE trial and save up to 30% afterward!

Mark on user profile

  • fioresns
  • fioresns
  • OFFLINE
  • Posts: 66
  • Thanks: 7
  • Karma: 0
5 days 5 hours ago #339999 by fioresns
Mark on user profile was created by fioresns
Hello again! I was wondering if there's a way (or a plugin) to make different users (other than admins, guests, etc), with a mark on the profile.
Something like, maybe: a senior member, a frequent poster... each with some kind of stamp or mark on the user profile and profile pic.

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48704
  • Thanks: 8319
  • Karma: 1447
4 days 22 hours ago #340002 by krileon
Replied by krileon on topic Mark on user profile
Yes, it's how I have a helmet icon next to my name. You don't need a plugin to do this as it's just built in.

Our substitution API supports IF conditions. You can use those IF conditions to add extra content to field layout parameters (like for the formatname field) to display additional information or in a Custom HTML field. See the bottom of our substitution tutorial below.

www.joomlapolis.com/documentation/127-community-builder/279-tutorials/18353-using-substitutions-throughout-cb

You can check if they have a specific field value, check if they have a specific view access level, or even if they've a specific Joomla usergroup.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.
The following user(s) said Thank You: fioresns

Please Log in or Create an account to join the conversation.

  • fioresns
  • fioresns
  • OFFLINE
  • Posts: 66
  • Thanks: 7
  • Karma: 0
4 days 19 hours ago #340012 by fioresns
Replied by fioresns on topic Mark on user profile
Sorry to ask, but I can't get through. I made a new field (cb_userstatus), checkbox type, with 3 options in the value rows. Where am I supposed to insert the html code?
Btw, I first added the field in a new Tab, but I guess I could avoid this using an existing tab (like profile foto). Is it so?
 

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48704
  • Thanks: 8319
  • Karma: 1447
4 days 17 hours ago #340013 by krileon
Replied by krileon on topic Mark on user profile

Sorry to ask, but I can't get through. I made a new field (cb_userstatus), checkbox type, with 3 options in the value rows. Where am I supposed to insert the html code?

Depends on what you want it to display and where. If you just want it to display something different on profile then you can use the profile layout parameters. Under Parameters > Layout use the Profile Value Layout to customize how it displays on profiles. Example as follows.
Code:
[cb:if cb_userstatus="elder"]ELDER[/cb:if] [cb:if cb_userstatus="staff"]STAFF[/cb:if] [cb:if cb_userstatus="fan"]FAN[/cb:if]

You're basically conditioning against the fields value with these IF substitutions. It will then display whatever you put inside the IF substitution. In my example it's just text, but this could be an image if you wanted.

Btw, I first added the field in a new Tab, but I guess I could avoid this using an existing tab (like profile foto). Is it so?

You can add it to an existing tab, yes.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

  • fioresns
  • fioresns
  • OFFLINE
  • Posts: 66
  • Thanks: 7
  • Karma: 0
4 days 3 hours ago #340017 by fioresns
Replied by fioresns on topic Mark on user profile
Ok, it worked, based on your advice. I managed to mark the text ELDER in the account tab, or in various positions making a new tab and selecting position for that.
But it only works for the profile page.
But how can I make the status affect the profile photo or the name people see in the stream?

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48704
  • Thanks: 8319
  • Karma: 1447
3 days 22 hours ago #340018 by krileon
Replied by krileon on topic Mark on user profile
Profile photo is a bit tricky. You'd need to write custom CSS so it'll properly float on top of the image and will probably need a background and other styling. Name is rather simple. Edit the formatname field then just add that field to the profile value layout of the formatname field. Example as follows.
Code:
[cb:if cb_userstatus="elder"]ELDER[/cb:if] [value]

Note the [value] it's important that is there so the name itself still displays. For avatar it's the same situation. You add it to the profile value layout and then you'll need to add your CSS as needed. You can also add it to the same tabs as the avatar and have it output to profile then write CSS for its field, but it's a bit easier just working within the layout parameters.

Also note this only applies to profile views. The formatname field is output as list view when it's used for linking to profiles. So this means in activity streams it's the list view. So you'll also need to adjust the userlist value layout if you also want it to apply there with the same example shown above.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum