Announcement

Collapse
No announcement yet.

Customizacion del conversation_userinfo

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Customizacion del conversation_userinfo

    Cuando tenia la version Vbulletin4 tenia customizado los siguientes campos:

    <dl class="userinfo_extra">
    <vb:if condition="$post['field7']"><div class="postbit">{vb:raw post.field7} <vb:if condition="is_member_of($bbuserinfo, 1,6)">{vb:raw post.field8}</vb:if></div></vb:if>
    <vb:if condition="$post['joindate']"><div class="postbit"><dt>{vb:rawphrase join_date}</dt> <dd>{vb:raw post.joindate}</dd></div></vb:if>
    <vb:if condition="$post['field2']"><div class="postbit"><dt>{vb:rawphrase location_perm}</dt> <dd>{vb:raw post.field2}</dd></div></vb:if>
    <vb:if condition="$post['age']"><div class="postbit"><dt>{vb:rawphrase age}</dt> <dd>{vb:raw post.age}</dd></div></vb:if>
    <!-- <div class="postbit"><dt>{vb:rawphrase posts}</dt> <dd>{vb:raw post.posts}</dd></div>
    {vb:raw template_hook.postbit_userinfo_right_after_posts} -->
    </dl>

    En vbulletin 5 no me deja usar el mismo formato de programacion y no lo entiendo mucho, alguien podria ayudarme a agregar un campo?

  • #2
    Yo logre hacer esto:

    Click image for larger version

Name:	2014-08-28_0-52-39.png
Views:	1
Size:	41.7 KB
ID:	4130863
    No se si es lo que quiere usted lograr ?

    El conversation_userinfo lo arme asi:

    PHP Code:
    {vb:set schemaAuthor.itempropauthor}
    {
    vb:set schemaAuthor.itemscope1}
    {
    vb:set schemaAuthor.itemtypehttp://schema.org/Person}
    <div class="userinfo b-userinfo b-post__hide-when-deleted" {vb:schema {vb:raw schemaAuthor}}>
        <
    vb:if condition="$user['showavatars']">
            <
    vb:if condition="!$conversation['userid']">
                <
    span class="b-avatar b-avatar--m b-avatar--thread h-margin-bottom-l"><img src="{vb:raw baseurl_corecdn}/images/default/default_avatar_medium.png" width="64" height="64" alt="{vb:phrase guest_avatar}" title="{vb:phrase guest_avatar}" /></span>
            <
    vb:elseif condition="$conversation['senderAvatar'] AND $conversation['senderAvatar']['avatarpath'] AND $conversation['senderAvatar']['hascustom']" />
                <
    a href="{vb:url 'profile', {vb:raw conversation}}" class="b-avatar b-avatar--m b-avatar--thread h-margin-bottom-l"><img src="{vb:raw baseurl_corecdn}/{vb:raw conversation.senderAvatar.avatarpath}" alt="{vb:raw conversation.authorname}" title="{vb:raw conversation.authorname}" /></a>
            <
    vb:elseif condition="$conversation['avatar'] AND $conversation['avatar']['avatarpath'] AND $conversation['avatar']['hascustom']" />
                <
    a href="{vb:url 'profile', {vb:raw conversation}}" class="b-avatar b-avatar--m b-avatar--thread h-margin-bottom-l"><img src="{vb:raw baseurl_corecdn}/{vb:raw conversation.avatar.avatarpath}" alt="{vb:raw conversation.authorname}" title="{vb:raw conversation.authorname}" /></a>
            <
    vb:else />
                <
    a href="{vb:url 'profile', {vb:raw conversation}}" class="b-avatar b-avatar--m b-avatar--thread h-margin-bottom-l"><img src="{vb:raw baseurl_corecdn}/images/default/default_avatar_medium.png" width="64" height="64" alt="{vb:raw conversation.authorname}" title="{vb:raw conversation.authorname}" /></a>
            </
    vb:if>
        </
    vb:if>

        <!-- 
    responsive alterationAdded userinfo-details wrapper in order to
        support left floated avatar with all other information on the right
    . -->
        {
    vb:set userInfo, {vb:raw conversation.userinfo}}
        <
    div class="b-userinfo__details">
            {
    vb:set schemaAuthor.itempropname}
            <
    div class="author h-text-size--14"><strong><vb:if condition="$conversation['userid'] > 0"><a href="{vb:url 'profile', {vb:raw conversation}}" {vb:schema schemaAuthor}><vb:if condition="isset($conversation['musername'])">{vb:raw conversation.musername}<vb:else />{vb:raw conversation.authorname}</vb:if></a><vb:else />{vb:phrase guest}</vb:if></strong></div>
            <
    vb:if condition="!empty($userInfo['usertitle'])">
                <
    div class="usertitle">
                <
    vb:if condition="$userInfo['customtitle'] == 2">
                    {
    vb:var userInfo.usertitle}
                <
    vb:else />
                    {
    vb:raw userInfo.usertitle}
                </
    vb:if>
                </
    div>
            </
    vb:if>
            {
    vb:set reputationimglevel {vb:raw conversation.reputationimg.level}}

            <
    div class="b-meter h-margin-top-m {vb:raw reputationimg.type}" title="{vb:rawphrase {vb:raw reputationimglevel}}">
                {
    vb:set counter, {vb:php range1,5}}
                <
    vb:each from="counter" value="nr">
                    <
    div class="b-meter__bar<vb:if condition="$conversation['reputationimg']['bars'] >= $nr"> b-meter__bar--selected</vb:if>"></div>
                    <
    div class="b-meter__bar<vb:if condition="$conversation['reputationimg']['bars'] >= $nr"> b-meter__bar--selected</vb:if>"></div>
                </
    vb:each>
            </
    div>
            
            <
    div class="b-userinfo__rank h-margin-top-s{vb:if empty($userInfo['rank']), ' h-hide'}">{vb:raw userInfo.rank}</div>
            
            <
    ul class="b-userinfo__additional-info-block h-margin-top-xl">
                <
    vb:if condition="$conversation['userid'] > 0">
                    <
    li class="b-userinfo__additional-info"><label>{vb:phrase join_date}:</label> <span>{vb:date {vb:raw userInfo['joindate']}, 'registered'}</span></li>
                    <
    li class="b-userinfo__additional-info"><label>{vb:phrase posts}:</label> <span>{vb:raw userInfo['posts']}</span></li>
                    <
    vb:if condition="$conversation['postelements'] == 4">
                        <
    li class="b-userinfo__additional-info"><label>{vb:phrase infractions}:</phrase><span>{vb:raw conversation.warnings}/{vb:raw conversation.infractions} ({vb:raw conversation.ipoints})</span></li>
                    </
    vb:if>
                </
    vb:if>
                {
    vb:hook 'conversation_userstats'}
            </
    ul>
            <
    ul class="b-userinfo__icons h-margin-none OLD__userinfo-extra OLD__icons">
                <
    vb:if condition="$conversation['online'] == 'online'">
                    {
    vb:set olstatus' online'}
                <
    vb:else />
                    {
    vb:set olstatus' offline'}
                </
    vb:if>
                <
    li class="b-userinfo__icon h-left OLD__online-status{vb:raw olstatus}" title="<vb:if condition="$olstatus == ' online'">{vb:rawphrase x_is_online_now, {vb:raw conversation.authorname}}<vb:else />{vb:rawphrase x_is_offline, {vb:raw conversation.authorname}}</vb:if>"><span class="b-icon b-icon__status--<vb:if condition="$conversation['online']=='online'">green<vb:else />gray</vb:if>"></span></li>

                {
    vb:template conversation_signaturetype=collapsedconversation={vb:raw conversation}, collapsedClass="b-userinfo__icon h-left"}
            </
    ul>
        </
    div>
    </
    div


    Yo lo que no e podido es bolver a poner las banderas (flags) para que muestre la img de la bandera en ves de decir el pais ...

    Comment


    • #3
      Logre poner las banderas (flags).

      Cualquier cosa me avisan y les doy una mano

      Click image for larger version

Name:	fff.png
Views:	2
Size:	43.5 KB
ID:	4130922
      Attached Files

      Comment


      • #4
        DesignMVD Sería de gran ayuda que nos dijeras cómo lo has hecho.

        Lo estoy intentando, pero no me funciona el código de vB4.
        HTML Code:
        <!— añadir dispositivo-->
        
        <vb:if condition="$post['field7']">
        
                        <img src="{vb:stylevar imgdir_misc}/idevice/{vb:raw post.field7}.png" alt="{vb:raw post.field7}" align=“left” />
        
        </vb:if>
        
        <!— final añadir dispositivo —>
        Saludos

        Comment


        • #5
          Yo también lo he conseguido siguiendo estos pasos:
          https://www.vbulletin.org/forum/showthread.php?t=297041

          incluyendo el comentario del mensaje #11 https://www.vbulletin.org/forum/show...4&postcount=11

          Comment

          Working...
          X