How to Post the Farsi Language in My WordPress Blog

104 16

    Get Started Typing Farsi in Your Blog

    • 1). Go to "Start" on the Windows taskbar and open "Control Panel." Double-click the "Regional and Language Options" icon and click on the "Keyboards and Languages" tab. Click "Change Keyboards" and add a keyboard.

    • 2). Scroll down the list of languages in the "Add Input Language" screen and click the plus sign next to Persian. Click the plus sign next to "Keyboard" under "Persian" and check the box next to "Persian." Click "OK" to exit the screen and then "OK" again to finish saving the new keyboard.

    • 3). Click the "EN" symbol next to your icon tray in the taskbar and select Persian to turn on the Farsi keyboard.

    • 4). Log in to the WordPress dashboard from the wp-admin directory and navigate to "Posts." Create a new post and begin typing Farsi. Click the blue "Publish" button to save the post to your blog.

    Make Style Sheet Changes for Right-to-Left Languages

    • 1). Download the style.css file used for your blog's current theme. You can grab this file by using an FTP client and going to /wp-content/themes/themename/ or by navigating to the "Edit Themes" screen under "Appearance" and copying and pasting the file's code.

    • 2). Go to "Start" on the Windows taskbar and type in the name of your code editor or Notepad. Open your style.css file in this program. Create a blank file and save it as rtl.css. Paste the code from style.css into the new file.

    • 3). Find the code in your CSS file that looks like this:

      body {

      ...property-value pairs here...

      }

      Add the following code between the curly braces:

      direction:rtl;

      unicode-bidi: embed;

    • 4). Go through your entire style sheet and remove any code that does not specify any right or left margins, padding, floats or positions. Where you find "right" or "left" anywhere in the code, replace it with the opposite direction. Be careful of shorthand properties such as "margin," where the value of each direction is shown in one list; these values specify directions going clockwise.

    • 5). Go back the WordPress dashboard and navigate to "Editor" from "Appearance." Open your header.php file and find this line of code:

      <link href="/links/?u=<?php bloginfo('stylesheet_uri'); ?>/style.css" rel="stylesheet" type="text/css" />

      Copy this line and paste it below the original. Change "style.css" to "rtl.css."

    • 6). Upload the rtl.css file to the main directory of your theme. Now you can use Farsi in your entire website, as long as you edit the theme templates to translate them.

Source...
Subscribe to our newsletter
Sign up here to get the latest news, updates and special offers delivered directly to your inbox.
You can unsubscribe at any time

Leave A Reply

Your email address will not be published.