Support ForumHow to left align text within a button – Support Forum https://support.ishyoboy.com/forums/topic/how-to-left-align-text-within-a-button/feed/ Mon, 06 May 2024 07:59:03 +0200 http://bbpress.org/?v=2.5.12-6148 en-US https://support.ishyoboy.com/forums/topic/how-to-left-align-text-within-a-button/#post-1080 <![CDATA[How to left align text within a button]]> https://support.ishyoboy.com/forums/topic/how-to-left-align-text-within-a-button/#post-1080 Sat, 02 Nov 2013 19:25:56 +0000 michael I’m trying to have the text within a button be left aligned.

In the Nalleto demo I found the shortcode below at home > Shortcodes > Buttons

*** shortcode from Nalleto ***

[button url=”#” size=”big” color=”color3″ new_window=”yes” full_width=”no” align=”right”] … [/button]

*** end of shortcode from Nalleto ***

next to a button with left aligned text within said button. But when I use this shortcode my button text is center aligned.

I realize the “align” attribute of the “button” shortcode has to do with where the button itself aligns, rather than the text within.

Any help on how to do this would be appreciated!

Thank you,

mike

]]>
https://support.ishyoboy.com/forums/topic/how-to-left-align-text-within-a-button/#post-1086 <![CDATA[Reply To: How to left align text within a button]]> https://support.ishyoboy.com/forums/topic/how-to-left-align-text-within-a-button/#post-1086 Sun, 03 Nov 2013 08:54:10 +0000 IshYoBoy Hey Mike,

You are right! The “align” attribute is not for the text within the button but for the whole button’s position, since not all buttons are full-width.

To achieve what you’re trying to, either use the “style” attribute (available in every shortcode) and add CSS to left-align the text E.g.:

[button ... style="text-align: left;"] … [/button]

or use the “css_class” attribute (available in every shortcode) to add a class and use it for styling later:

[button ... css_class="mikes-leftalign"] … [/button]

and add Custom CSS style:

You can then apply this class to any shortcode you wish.
Hope this helped.

Cheers

A 5 star rating is always a great motivation for us if you are happy with our theme or support!
Themeforest | MojoMarketplace | Creative Market

]]>