Title: Heading widget background text
Last modified: March 12, 2024

---

# Heading widget background text

 *  Resolved [planetboris](https://wordpress.org/support/users/planetboris/)
 * (@planetboris)
 * [2 years, 2 months ago](https://wordpress.org/support/topic/heading-widget-background-text/)
 * Hi, I am using your very nice Heading widget, perfect for my design requirements.
   I would like to center align the background text. There is no option to do that
   as I could see in the settings. I tried the following css: “selector .premium-
   title-container style4 premium-title-bg-text {text-align: center}” but it is 
   not working. Hope you have some advice on how to accomplish center aligned background
   text.

Viewing 5 replies - 1 through 5 (of 5 total)

 *  Plugin Author [Leap13](https://wordpress.org/support/users/leap13/)
 * (@leap13)
 * [2 years, 2 months ago](https://wordpress.org/support/topic/heading-widget-background-text/#post-17492966)
 * Hi there,
 * Please share a page link where I can see the issue so I can have a look and see
   what is going there.
 *  Thread Starter [planetboris](https://wordpress.org/support/users/planetboris/)
 * (@planetboris)
 * [2 years, 2 months ago](https://wordpress.org/support/topic/heading-widget-background-text/#post-17495704)
 * Hi, in this case a page link would not be relevant. It is not an “issue” I am
   having, rather a limitation of the widget, which, as mentioned in my last message,
   could possibly be resolved through CSS and the correct class name. You can try
   this yourself. **There is no center align setting for the background text.** 
   I created 2 screenshot where you can visualize why this is necessary for my design.
   In the first screen shot you can see the way I have set up the Heading style,
   main heading in the center with the background text below, this is **1920 X 1080**.
   It looks centered, right? Ok, but when you view it on a smaller screen size, 
   in this example of the 2nd screenshot, at **1600 X 900** (_still within desktop
   range_), you can see it is shifting over to the side and is no longer centered.
   So I need the CSS to “force” the background text to always be centered at all
   various screen sizes. [https://postimg.cc/gallery/QWz7QhY](https://postimg.cc/gallery/QWz7QhY)
 *  Plugin Author [Leap13](https://wordpress.org/support/users/leap13/)
 * (@leap13)
 * [2 years, 2 months ago](https://wordpress.org/support/topic/heading-widget-background-text/#post-17496286)
 * Try the CSS below:
 *     ```wp-block-code
       .premium-title-bg-text::before {
           top: 50%;
           left: 50%;
           transform: translate(-50%,-50%) !important;
       }
       ```
   
 *  Thread Starter [planetboris](https://wordpress.org/support/users/planetboris/)
 * (@planetboris)
 * [2 years, 2 months ago](https://wordpress.org/support/topic/heading-widget-background-text/#post-17506215)
 * Thanks very much for the code, but unfortunately it didn’t work, sub heading 
   still aligns to the left. However I found a solution with Essential Addons Dual-
   Color Heading widget which has dual headings included, which acts as a sub heading
   feature with center align function. Thanks anyways for trying to help. Cheers
 *  Plugin Author [Leap13](https://wordpress.org/support/users/leap13/)
 * (@leap13)
 * [2 years, 2 months ago](https://wordpress.org/support/topic/heading-widget-background-text/#post-17506253)
 * Hi [@planetboris](https://wordpress.org/support/users/planetboris/)
 * So sorry to hear that it didn’t work. I would be more than glad to help. Could
   you please just share a link where I can see the widget after you added the CSS
   above?
 * Regards

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Heading widget background text’ is closed to new replies.

 * ![](https://ps.w.org/premium-addons-for-elementor/assets/icon-128x128.gif?rev
   =3495451)
 * [Premium Addons for Elementor - Powerful Elementor Templates & Widgets](https://wordpress.org/plugins/premium-addons-for-elementor/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/premium-addons-for-elementor/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/premium-addons-for-elementor/)
 * [Active Topics](https://wordpress.org/support/plugin/premium-addons-for-elementor/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/premium-addons-for-elementor/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/premium-addons-for-elementor/reviews/)

 * 5 replies
 * 2 participants
 * Last reply from: [Leap13](https://wordpress.org/support/users/leap13/)
 * Last activity: [2 years, 2 months ago](https://wordpress.org/support/topic/heading-widget-background-text/#post-17506253)
 * Status: resolved