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

2 Different Sigs for 2 Different Forum Styles?:

Discussion in 'Styling and Customization Questions' started by CritiKiL, Oct 14, 2012.

  1. CritiKiL

    CritiKiL Active Member

    Ok. I have a regular forum style and then I have a mobile one. The regular style I want it to show 'one type' of signature of the user, but when switched to the mobile style I want a second signature type to show. Both types of sigs should be editable in the persons profile area (ex: Sig 1 style and Sig 2 style). BUT 'Sig 1' style will only show in the regular forum and the 'Sig 2' style will only show in the mobile style. Thanks in advance ;-)
     
  2. 0xym0r0n

    0xym0r0n Well-Known Member

    I would replace the signature area with a custom user field option in the template :) *like my psn/xbl/steam tutorial but find the template wrapper for the posts and remove the signature bit and replace with custom user field entry*
     
  3. CritiKiL

    CritiKiL Active Member

    Sounds difficult to do. Was looking for someone with the knowledge to provide me with the solution of just me adding or removing existing code? Thanks though, 0xym0r0n (n)
     
  4. 0xym0r0n

    0xym0r0n Well-Known Member

    Ah and I didn't think about the bbcode showing :) My idea would work and it's fast but I've not a clue how to get bbcode working with it :p
    Otherwise I'd just make a TMS and attach it here for you.
    Maybe there's a callback method or something I'll look into it. I just disable mine on mobile
    Code:
    .message .signature
    {
    display: none;
    }
    ^Source: http://xenforo.com/community/threads/disable-signature-for-a-specific-style.35005/

    And the template is message

    Code:
            <xen:if is="{$visitor.content_show_signature} && {$message.signature}">
     
  5. CritiKiL

    CritiKiL Active Member

    Not looking to disable "anything" bro.
     
  6. 0xym0r0n

    0xym0r0n Well-Known Member

    I understand I guess what I'm trying to do is explain how to do it, if no one provides you an add-on.

    You disable the normal signature on your mobile style, then you add the custom signature code in the message template of mobile theme. If the original signature is not disabled by css or removed in the template, then you will get two signatures.

    That's what I mean.

    I'll make an template modification if no one beats me to it. I've got to release a few things tonight anyways.
     
    CritiKiL likes this.
  7. CritiKiL

    CritiKiL Active Member

    No worries because Version 1.0.6 of XFS Mobile puts a checkbox for you to disable or enable the sigs ;-).
     
  8. 0xym0r0n

    0xym0r0n Well-Known Member

    indeed but if you were to make your own style :) You, of course, having the XFS mobile would just check this option lol.
     
    CritiKiL likes this.
  9. CritiKiL

    CritiKiL Active Member

    sig_test1.png sig_test2.png

    I want the best of both worlds. I want my animated sigs (nobody else can make them but me - it seems!) to show on forum and then I want a 'solid mobile-version' to show from the mobile. I would of course make both versions of sigs for my clan members.
     
  10. CritiKiL

    CritiKiL Active Member

    Hello. Does anyone have any ideas for this to work? I would be willing to [PAID] for a solution.
     
  11. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    You can edit this template directly:

    Admin CP -> Appearance -> Templates -> message

    And use this variable to output a specific field anywhere you want (you must enter the field_id of your custom field):

    Code:
    {$message.customFields.field_id}
    
    So you can replace the signature with a different custom field by editing that template in each style.
     
    CritiKiL likes this.
  12. CritiKiL

    CritiKiL Active Member

    I'm trying to but am getting lost in this Jake. How will this code be able to allow me to post up two signature spots in the profile areas, but each style show a different one? For example, there's a place already for one sig input. I'm rusty on the custom field creation and how to set them correctly, so could you give me point-by-point instructions? Thanks man.
     
  13. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    You can create custom fields in your:

    Admin CP -> Users -> Custom User Fields

    Then edit that template:

    Admin CP -> Appearance -> Templates -> message

    Find this signature code:

    Code:
    		<xen:if is="{$visitor.content_show_signature} && {$message.signature}">
    			<div class="baseHtml signature ugc{xen:if $message.isIgnored, ' ignored'}"><aside>{xen:raw $message.signatureHtml}</aside></div>
    		</xen:if>
    
    Replace with:

    Code:
    		<xen:if is="{$visitor.content_show_signature} && {$message.customFields.field_id}">
    			<div class="baseHtml signature ugc{xen:if $message.isIgnored, ' ignored'}"><aside>{$message.customFields.field_id}</aside></div>
    		</xen:if>
    
     
  14. CritiKiL

    CritiKiL Active Member

    Ok, I think I have it but there is a problem with how I get the custom user field to understand the sig code (BB Code):
     

    Attached Files:

  15. CritiKiL

    CritiKiL Active Member

    Update, but not what I wanted:

    I proceeded to add this to the code you gave me above and 'only used the url link' of the sig image itself. But originally the sig's are automatically resized and this way does not seem to do that at all (sigs are not resized automatically):

    Code:
    <xen:if is="{$visitor.content_show_signature} && {$message.customFields.sig2}">
      
                    <img src="{$message.customFields.sig2}" />
     
                    </xen:if>
    I basically just wanted to be able to put the 'same BBCode' of a different sig into a custom user field but without being able to make the custom user field understand BBCode it's not going to work out. Anyway I can get this working 'with autoresizing' working? I'm sure that I did some mod for the sigs and other images to resize themselves...
     
  16. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    Parsing the custom fields for BB code would require an addon to extend the view. It's not a simple template edit.
     
  17. CritiKiL

    CritiKiL Active Member

    I see. Would changing the input from BBcode to html code allow a way to do this without extensive addon? And is there an available addon for the BBCode already, or would someone have to make one from scratch?
     
  18. CritiKiL

    CritiKiL Active Member

    Ok, I have another question. When I use the XFS Mobile it does not resize my sig "because the sig uses five separate files. How can I fix it so that all the files together are resized? ~ it resizes one file with no problem but when it's more than one file in the sig box it doesn't resize any of them.
     
  19. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

  20. rootsxrocks

    rootsxrocks Active Member

    Is there a way to disable signatures in certain forums or to make a change to the default "Show people's signatures with their messages" to be unchecked on current groups and new registers ?
     

Share This Page