Limit Size of Signatures Hitskin_logo Hitskin.com

This is a Hitskin.com skin preview
Install the skinReturn to the skin page

The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.
4 posters

    Limit Size of Signatures

    TruthSayer
    TruthSayer
    Forumember


    Female Posts : 184
    Reputation : 21
    Language : English, ALS, Med-speech, Pig Latin ^_^
    Location : Wouldn't you like to know... O.o

    Solved Limit Size of Signatures

    Post by TruthSayer July 26th 2011, 3:33 am

    I'm wondering if there's a way to limit the size of pictures that are allowed in member signatures. I've found this, but I use phpBB2, so I'm not sure if the site will work for me.

    Also, is there a way to automatically resize signature images down to the maximum size allowed?

    And since I know absolutely nothing about javascript or HTML, please tell me where to put the code, if there is one?

    Thanks in advance!
    avatar
    Mystic_gohan2
    Forumember


    Posts : 700
    Reputation : 30
    Language : English

    Solved Re: Limit Size of Signatures

    Post by Mystic_gohan2 July 26th 2011, 3:40 am

    Code:
    signature_div img {
     max-width: SIZEpx; max-height: SIZEpx;
     }

    Change "SIZE" and "SIZE" with the size Smile in pixels . add it to

    CSS style sheet .
    TruthSayer
    TruthSayer
    Forumember


    Female Posts : 184
    Reputation : 21
    Language : English, ALS, Med-speech, Pig Latin ^_^
    Location : Wouldn't you like to know... O.o

    Solved Re: Limit Size of Signatures

    Post by TruthSayer July 26th 2011, 3:52 am

    Thank you so much for your quick reply!

    I've put this into the style sheet, but signatures are still larger than the max I've set. Does this only work for signature images put in the future, or should it work for all signatures that already exist?
    Nera.
    Nera.
    Energetic


    Female Posts : 7078
    Reputation : 2017
    Language : English
    Location : -

    Solved Re: Limit Size of Signatures

    Post by Nera. July 26th 2011, 10:58 am

    It should work for all signatures Smile
    TruthSayer
    TruthSayer
    Forumember


    Female Posts : 184
    Reputation : 21
    Language : English, ALS, Med-speech, Pig Latin ^_^
    Location : Wouldn't you like to know... O.o

    Solved Re: Limit Size of Signatures

    Post by TruthSayer July 27th 2011, 2:00 am

    Hm. The signatures haven't shrunk, and although they're not considered huge, they're still larger than the specified pixels.

    The specified width of the signatures are within bounds (less than 500px), but the height is 100px over what it should be per the code.
    avatar
    Guest
    Guest


    Solved Re: Limit Size of Signatures

    Post by Guest July 27th 2011, 2:17 am

    The reason this isn't working for you is because the CSS given above is incorrect. Since you stated 500x100, the correct CSS is:

    Code:
    .signature_div img {max-width:500px;max-height:100px;}
    However, this still won't stop people from flooding their signatures with multiple images. I've found the best way to limit the sizes of signatures is with the following CSS:

    Code:
    .signature_div {max-width:90%;max-height:150px;overflow:auto;}
    This will allow a member to put whatever they want into their signature, but if they put too much, scrollbars will appear. Not only does this keep a board looking clean, it's a subtle hint to people abusing signatures to change their signature to something that fits within your proscribed boundaries.
    TruthSayer
    TruthSayer
    Forumember


    Female Posts : 184
    Reputation : 21
    Language : English, ALS, Med-speech, Pig Latin ^_^
    Location : Wouldn't you like to know... O.o

    Solved Re: Limit Size of Signatures

    Post by TruthSayer July 27th 2011, 3:27 am

    dion, this works perfectly, and I love the scroll bar!

    Nera, thanks so much for your help!

    Both of you absolutely rock!
    Jophy
    Jophy
    ForumGuru


    Male Posts : 17922
    Reputation : 836
    Language : English
    Location : Somewhere

    Solved Re: Limit Size of Signatures

    Post by Jophy July 27th 2011, 5:50 am

    Limit Size of Signatures Solved10Since this thread appears to be solved, I will lock this thread and mark it as solved now.

    Important: You can also help the moderators to know if your topic/problem is solved by EDITING your first post and marking the topic as solved. Thank you.

    ~ Joph25