XF 2.1 Style and fix custom field on post bit

CranberryPie

New member
Hello,

I have "Identities" on my board and set Twitch to show up on my members post bit. I got it working and all, although I want to remove the title of the custom field Twitch as you see in the image below. And I want to stack these images horizontally instead of vertically. Is this doable without affect the other post bit information?

Code:
<a href="https://twitch.com/Profile?{$value}" target="_blank"><img src="https://webserver.com/images/profileicons/twitch.png" alt="Twitch"/></a>

When I hover over the Twitch icon "alt" doesn't work? A little pointer appears. twitch.png
 
you could try:
Code:
<a href="https://twitch.com/Profile?{$value}" class="twitchText" target="_blank"><img src="https://webserver.com/images/profileicons/twitch.png"  data-xf-init="tooltip" title="Twitch"/></a>

extra.less:
.twitchText {text-indent: -9999px;} /* sends the text off-screen */



or you could install
 
Gamer profiles doesn't work for me, and it was kind of a pain to uninstall, certain items got left over, at least in XF 2.1.

The CSS didn't work, I've also tried CSS column and float to no avail. Maybe it's the custom field titles?

Tool tip works great though! :D

Regards.
 
Hello,

I have "Identities" on my board and set Twitch to show up on my members post bit. I got it working and all, although I want to remove the title of the custom field Twitch as you see in the image below. And I want to stack these images horizontally instead of vertically. Is this doable without affect the other post bit information?

Code:
<a href="https://twitch.com/Profile?{$value}" target="_blank"><img src="https://webserver.com/images/profileicons/twitch.png" alt="Twitch"/></a>

When I hover over the Twitch icon "alt" doesn't work? A little pointer appears. View attachment 234428
this process will only list the icons vertically. Try un-ticking this option to show on user info and if comfortable with editing templates

message_macros - find
Code:
<div class="message-userExtras">
                                <xf:contentcheck>

add after:
Code:
<!---Identities--->
<xf:if is="{$user.Profile.custom_fields.Twitch}"><a href="https://twitch.com/Profile?{$user.Profile.custom_fields.Twitch}" target="_blank"><img src="https://webserver.com/images/profileicons/twitch.png"  data-xf-init="tooltip" title="{$user.username}'s Twitch";></a></xf:if>
<!---Identities --->

You can use the same template for the rest of your "identities" and just replace "twitch" with the title of the custom user field.
 
Thank you! It's perfect!

Where do you find the XF variables and CSS classes so if need be I can edit these myself in the future? I tried looking online and the manual and didn't find anything.
 
This should help.

 
Do you know how to turn off or fix XF tool tip under "Contact" details when hovering over custom field data.View attachment 234505
it may not be the prettiest way but this should fix the tooltip placement.

find on template near top:
member_view:
Code:
<xf:macro template="metadata_macros" name="metadata"



add before:
Code:
<style>
.pairs.pairs--columns {display: block !important;}
</style>

1599596589787.png
 
Last edited:
Top Bottom