WordPress.org

Ready to get started?Download WordPress

Forums

how to increase font size of post text content for specific language (5 posts)

  1. sallam
    Member
    Posted 4 years ago #

    Greetings
    Is there a way that I can increase the font size of all post text content? I find text size too small, and it would be nice to set a larger font size instead of having to set it with each new post I make.

    I write English and Arabic posts. English font size is fine, but Arabic is too small. Is there a way to increase the font size that applies only on Arabic?

  2. esmi
    Forum Moderator
    Posted 4 years ago #

    The font size can be increased via your theme's stylesheet. The tricky part would be adding something that distinguished English posts from Arabic ones if you wanted to just increase the text size in the latter.

  3. sallam
    Member
    Posted 4 years ago #

    Thanks for your reply. Yes that's exactly what I want, to increase only Arabic font size. I do hope that someone can help me with the code needed for that.

  4. esmi
    Forum Moderator
    Posted 4 years ago #

    Two options off the top of my head:

    1. Create the Arabic posts in the HTML tab and surround the entire post content with something like <div class="Arabic">...</div> and then style on the text within that div.

    2. Use custom fields to add some sort of language value that could then be used to add a class automatically to Arabic posts.

    http://codex.wordpress.org/Using_Custom_Fields

  5. If you're mixing Arabic and English in the same post/page, Esmi's idea of a <div> will work. if you have a post/page all in Arabic, the custom field will do it automatically.

    Look in your style.css and see what the font-size is in body and p styles - em, px or % - and then bump that up for arabic. Might need a line-height to add spacing, too.

    #arabic { font-size: 1.2 em; line-height: 1.5em; }

Topic Closed

This topic has been closed to new replies.

About this Topic