Skip to Content Skip to Menu

🎃 Happy Halloween! Treat yourself with an awesome discount on memberships! Get 20% off now with code SPOOKY-2024!

[SOLVED] link to k2 user profile field

  • diogotu
  • diogotu
  • OFFLINE
  • Posts: 138
  • Thanks: 4
  • Karma: 0
11 years 4 months ago - 11 years 4 months ago #228599 by diogotu
Hi,

I would like to create a link to k2 user profile, something like:

Visit also:My K2 Profile

I have this code, that works inside k2
Code:
<div class="k2author"> <?php echo $user = JUser::getInstance($item->created_by) ?> <a href="<?php echo $link = K2HelperRoute::getUserRoute($user->id) ?>"><?php echo JUser::getInstance($item->created_by)->name; ?></a> </div>

but i tryied to creat a delimiter field with that code and no sucess, any tip for making this feature?

I am trying also to make a button inside k2 profile, like!

Visit also: My CB Profile

thanks
Last edit: 11 years 4 months ago by krileon.

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 48460
  • Thanks: 8280
  • Karma: 1443
11 years 4 months ago #228605 by krileon
Replied by krileon on topic link to k2 user profile field
You can't use code in a delimiter field. Only HTML and substitutions. The below should work fine.
Code:
<a href="index.php?option=com_k2&view=itemlist&task=user&id=[user_id]">My K2 Profile!</a>


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: diogotu

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

  • diogotu
  • diogotu
  • OFFLINE
  • Posts: 138
  • Thanks: 4
  • Karma: 0
11 years 4 months ago #228609 by diogotu
Replied by diogotu on topic link to k2 user profile field
Perfect!

thanks

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

Moderators: beatnantkrileon
Powered by Kunena Forum