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.
The forum of the forums
3 posters

    Script help and forum help

    ThePhantomHourglass
    ThePhantomHourglass
    New Member


    Male Posts : 11
    Reputation : 1
    Language : English

    Solved Script help and forum help

    Post by ThePhantomHourglass Fri 7 Mar - 0:09

    1) How do I disable users just changing colors of their forum post text? For example, hey have all the RICH/HTML Text Editor features, but they just can't change text color.

    2) What's a code that will make users in the Administrator and Moderator group (those are the exact group names on my forum) have red text on the forum? Ex. Any text users of these groups will post will be red. This is only supposed to appear on messages and forum topics posted by the user.
    vaccam
    vaccam
    Forumember


    Posts : 371
    Reputation : 14
    Language : Norwegian
    Location : Norway

    Solved Re: Script help and forum help

    Post by vaccam Fri 7 Mar - 0:37

    I dont think that is possible. I have tried myself but i cant figure it out.
    ThePhantomHourglass
    ThePhantomHourglass
    New Member


    Male Posts : 11
    Reputation : 1
    Language : English

    Solved Re: Script help and forum help

    Post by ThePhantomHourglass Fri 7 Mar - 0:52

    vaccam wrote:I dont think that is possible. I have tried myself but i cant figure it out.
    I was thinking what if after you make a post or edit the post, the script would detect if you're in the Moderator or Administrator group. If you are, then it edits and changes all the post text to red, if you're not, it changes all the post text to black.
    vaccam
    vaccam
    Forumember


    Posts : 371
    Reputation : 14
    Language : Norwegian
    Location : Norway

    Solved Re: Script help and forum help

    Post by vaccam Fri 7 Mar - 0:57

    That sounds complicated, there i cannot help you. Lets wait and see what a more professional coder comes along.

    Sorry that i couldnt help you any futher.

    Best regards

    Vaccam
    ThePhantomHourglass
    ThePhantomHourglass
    New Member


    Male Posts : 11
    Reputation : 1
    Language : English

    Solved Re: Script help and forum help

    Post by ThePhantomHourglass Fri 7 Mar - 1:01

    vaccam wrote:That sounds complicated, there i cannot help you. Lets wait and see what a more professional coder comes along.

    Sorry that i couldnt help you any futher.

    Best regards

    Vaccam
    That's alright. Thanks for seeing if you could help though. I'm guessing a staff member will be here soon to help.
    Ange Tuteur
    Ange Tuteur
    Forumaster


    Male Posts : 13207
    Reputation : 3000
    Language : English & 日本語
    Location : Pennsylvania

    Solved Re: Script help and forum help

    Post by Ange Tuteur Fri 7 Mar - 2:23

    Hello ThePhantomHourglass,

    First you should modify your staff ranks. Go to :
    Administration Panel > Users and groups > Ranks > Rank administration

    Edit, or create a title, make sure it is special too.

    You should wrap your title with these tags :
    Code:
    <span id="staffPost">Rank Title</span>
    Script help and forum help Captu378

    When finished modifying your staff ranks go to :
    Modules > Javascript codes management > create a new script

    Title : what you wish
    Placement : In the topics
    Paste the code below and save :
    Code:
    $(function() {
     Â   $('.post .entry-content font').removeAttr('color');
     Â   $('.post:has(#staffPost) .entry-content').attr('style','color:#f00;');
    });

    The color from font tags will be removed for posts. Posts with the rank title that is #Admin will have red color.

    Additionally if you wanted to hide the color palette :
    Display > Colors > CSS

    paste this to hide it :
    Code:
    .sceditor-button-color { display:none !important; }
    ThePhantomHourglass
    ThePhantomHourglass
    New Member


    Male Posts : 11
    Reputation : 1
    Language : English

    Solved Re: Script help and forum help

    Post by ThePhantomHourglass Fri 7 Mar - 3:39

    Ange Tuteur wrote:Hello ThePhantomHourglass,

    First you should modify your staff ranks. Go to :
    Administration Panel > Users and groups > Ranks > Rank administration

    Edit, or create a title, make sure it is special too.

    You should wrap your title with these tags :
    Code:
    <span id="staffPost">Rank Title</span>
    Script help and forum help Captu378

    When finished modifying your staff ranks go to :
    Modules > Javascript codes management > create a new script

    Title : what you wish
    Placement : In the topics
    Paste the code below and save :
    Code:
    $(function() {
     Â   $('.post .entry-content font').removeAttr('color');
     Â   $('.post:has(#staffPost) .entry-content').attr('style','color:#f00;');
    });

    The color from font tags will be removed for posts. Posts with the rank title that is #Admin will have red color.

    Additionally if you wanted to hide the color palette :
    Display > Colors > CSS

    paste this to hide it :
    Code:
    .sceditor-button-color { display:none !important; }
    Thanks! It worked!

    You can mark this as complete and archive now.
    Ange Tuteur
    Ange Tuteur
    Forumaster


    Male Posts : 13207
    Reputation : 3000
    Language : English & 日本語
    Location : Pennsylvania

    Solved Re: Script help and forum help

    Post by Ange Tuteur Fri 7 Mar - 3:46

    You're welcome I love you

    Topic solved and archived

      Current date/time is Sun 22 Sep - 18:37