WordPress.org

Forums

need a step by step how to do RTL (5 posts)

  1. ahsun
    Member
    Posted 3 years ago #

    i have installed the website in english and i want to post some articles in arabic as well, i can set post content to Left to right through align right tool in editor (Tell me if there is any better idea for this) but how i can do the same thing with post title? because its showing LTR on website.

  2. bryceadams
    Member
    Posted 3 years ago #

    I'm not 100% sure of your situation.. but you can probably just add some CSS to your style.css document for titles. If you post your site's link I can give you the exact code but you can probably just add:
    h1 {text-align:right;}
    to your CSS file.

    Look at 3 Different Ways to RTL your CSS for more help.

    EDIT: I did just realise that you have both English and Arabic on your site... and adding that code will align ALL titles to the right. In this case... the simplest solution I can think of (but very messy), is to add the following code in your titles for Arabic posts (this is also without messing with style.css but if you'd rather do that then you can do it that way too):

    <div style="text-align:right;">YOUR TITLE HERE</div>

    That should work.

  3. ahsun
    Member
    Posted 3 years ago #

    where to put this code brother? <div style="text-align:right;">YOUR TITLE HERE</div>

  4. bryceadams
    Member
    Posted 3 years ago #

    In the title area of the post where you'd normally put your English title.

  5. Tarsem Singh
    Member
    Posted 3 years ago #

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags