• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Changing colour of one button in text widget

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › Design Tips and Tricks › Changing colour of one button in text widget

This topic is: resolved
  • This topic has 4 replies, 2 voices, and was last updated 8 years, 8 months ago by Chrisrx.
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • September 22, 2017 at 6:14 am #211740
    Chrisrx
    Member

    Hi

    I am looking to change one button to a different colour that resides in a text widget, here is the code below:

    Contact Us

    Would you be able to advise how best to do this.

    Regards

    Chris

    http://www.roxhar.com
    September 22, 2017 at 7:57 am #211747
    Victor Font
    Moderator

    Add an ID to the link element and then create CSS just for that ID, or change the class name and create new CSS for that class.


    Regards,

    Victor
    https://victorfont.com/
    Call us toll free: 844-VIC-FONT (842-3668)
    Have you requested your free website audit yet?

    September 22, 2017 at 9:01 am #211750
    Chrisrx
    Member

    Hi Victor

    Is there anyway to add the colour through the text widget?, so adding

    style="color

    if not then I'm not sure how to implement your solution.

    Regards

    Chris

    September 22, 2017 at 9:20 am #211751
    Victor Font
    Moderator

    This is your code with the beginning and ending brackets removed so it doesn't render as a link in this post.

    a class="button" href="http://www.roxhar.com">Contact Us</a

    To add an id change this to:

    a id="contact-button" class="button" href="http://www.roxhar.com">Contact Us</a

    Then in style.css add the new style:

    #contact-button {
        background-color: #ccc;
        color: #222;
    }

    Make sure you add the new CSS after the .button class css in style.css.

    But to answer your new question, yes you can add the style as inline css on the element.


    Regards,

    Victor
    https://victorfont.com/
    Call us toll free: 844-VIC-FONT (842-3668)
    Have you requested your free website audit yet?

    September 25, 2017 at 2:52 am #211836
    Chrisrx
    Member

    Thank you Victor

    Worked perfectly

    Regards

    Chris

  • Author
    Posts
Viewing 5 posts - 1 through 5 (of 5 total)
  • The topic ‘Changing colour of one button in text widget’ is closed to new replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2026 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble