Dion Sune Jensen
Active member
I've added this to a site primarily full of casual gamers, is there any way to have it display their readable steam id?
$posts = $postModel->getAndMergeAttachmentsIntoPosts($posts);
/* TerminalAddict WAS HERE */
foreach ($posts as $key => $post)
{
$posts[$key]['identities'] = unserialize($post['identities']);
}
/* END TerminalAddict WAS HERE */
<xen:hook name="message_user_identities" params="{xen:array 'user={$user}'}">
<xen:foreach loop="{$user.identities}" key="$service1" value="$account1">
<xen:if is="{$service1} == 'Steam'">
<div class="steamprofile" title="{$account1}"></div>
</xen:if>
</xen:foreach>
<xen:if is="!in_array('Steam', {$user.identities})">
<div class="steamprofileNOT" title="No Steam"> <a href="account/contact-details">NO SteamID entered</a></div>
</xen:if>
</xen:hook>
<script type="text/javascript" src="/steamprofile/steamprofile.js"></script>
Can you tell me the alternatives? I am not familiar with these techniques.
Why can I not put HTML there normally?
member_view uses {xen:string censor, $identity.value} which escapes the html tags
Alternatives include editing the template (security concerns) or fiddling with one of the template hooks
attachment not work. See the plugin i post has everything you mentioned...
Be freakin awesome if this was ported over. Post bit is nice, but there are many more options here.here are a mod for phpbb may be able to get ideas. I had in my old forum and it worked great.
http://ghostfacekillerclan.com/downloads/steam_mod.zip
Install the Steam Identity Service:
http://xenforo.com/community/threads/steam-identity-service.9819/#post-140629
open up XenForo_ControllerPublic_Thread (library/XenForo/ControllerPublic/Thread.php) and after line ~69..
add...PHP:$posts = $postModel->getAndMergeAttachmentsIntoPosts($posts);
PHP:/* TerminalAddict WAS HERE */ foreach ($posts as $key => $post) { $posts[$key]['identities'] = unserialize($post['identities']); } /* END TerminalAddict WAS HERE */
in message_user_info add:
Code:<xen:hook name="message_user_identities" params="{xen:array 'user={$user}'}"> <xen:foreach loop="{$user.identities}" key="$service1" value="$account1"> <xen:if is="{$service1} == 'Steam'"> <div class="steamprofile" title="{$account1}"></div> </xen:if> </xen:foreach> <xen:if is="!in_array('Steam', {$user.identities})"> <div class="steamprofileNOT" title="No Steam"> <a href="account/contact-details">NO SteamID entered</a></div> </xen:if> </xen:hook>
in PAGE_CONTAINER just before </head>
add:
HTML:<script type="text/javascript" src="/steamprofile/steamprofile.js"></script>
example:
http://www.fps.net.nz/community/threads/hello.1485/
steam badges on each "post bit"
I imagine Darkimmortal will rewrite it to create a new custom profile field so that it still integrates with the Log in with Steam add-on.This add-on effectively just became obselete.
Anyone can easily add a custom profile field directly in the ACP for this now.
We use essential cookies to make this site work, and optional cookies to enhance your experience.