1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.4 xen:link to link to a profile

Discussion in 'Styling and Customization Questions' started by Mike Creuzer, Aug 22, 2014.

  1. Mike Creuzer

    Mike Creuzer Well-Known Member

    Hi there!

    I need to know what {xen:link XXX} would be to link to a $user's profile.

    Thanks,
    Mike
     
  2. Brogan

    Brogan XenForo Moderator Staff Member

    It would typically be something like {xen:link members, $user}

    But it depends where and how you are trying to use it.
     
    Mike Creuzer likes this.
  3. Mike Creuzer

    Mike Creuzer Well-Known Member

    Perfect thanks buddy! I searched through the templates, its not done because you generally use xen:user I think, but that wasn't going to work for me.
     
  4. RobinHood

    RobinHood Well-Known Member

    Would something like this work in the welcome conversation message?

    I'd like to use a generic link that will always link to the new users profile so they can check it out. Would the following work?

    Code:
    [URL='{xen:link members, $user}']profile[/url]
    
     
  5. Chris D

    Chris D XenForo Developer Staff Member

    Nope. xen:link only works inside templates.

    There are some placeholders that will work in the welcome conversation.

    Code:
    [url="http://<yourboardurl>/index.php?members/{id}"]profile[/url]
    {id} gets replaced with the user's ID.
     
    RobinHood likes this.
  6. RobinHood

    RobinHood Well-Known Member

    Perfect, thanks Chris :)
     

Share This Page