How to use Unicode Fonts in WordPress - wordpress

I would like to know how to use Unicode fonts in Word-press. I mean that I need to use Sinhalese fonts in the site. So how can i do that?
Thank you
Asanka

download google input tools for sinhala ( or what ever language you need ) from here http://www.google.com/inputtools/windows/ and install. You'll have to select language from the language toolbar at the task bar - right corner to type in sinhala.
Type what ever you need in sinhala in the wordpress post edit screen and publish. You'll see it in sinhala.

Related

WordPress responsive menu in chinese language

I am using this plugin in my wordpress website.
https://wordpress.org/plugins/wp-responsive-menu/
But when i translate my website in chinese language menu items not showing. Please can you suggets me how i can translate it?
in this plugins, the folder "lang" is empty... It does not use languages. So you need change php files and i recommend you do not do this.
But if you really need change, use sublimetext or other soft or command line for use best function : "search in folder".
Use WMPL[Multilingual Plugin].
Just install this plugin in your website and just translate each and every menu which has been used in English.{you can even Sync the menus to the selected language}.
When you choose your language the menu gets changed to Chinese language and nothing get affected.
You will most probably need to either change the page encoding or if use an approach like in this answer.
(HTML5) cannot display Chinese characters when using UTF-8

default language by polylang plugin not working

I installed Polylang Plugin and configed that but I have a problem when I set the default language in Persian language the site loaded in English mode and it is not deference if change default language because in any way in run site loaded by English version.
I installed 3 languages: Persian, English, French
Wordpress version is 4.1.1 and Polylang Plugin version is 1.8.5
How can I fixed the default language in fa-IR?
please help me
For me it was the Polylang setting
Detect browser language (When the front page is visited, set the
language according to the browser preference).
Found in wp-admin > languages > settings.
Test to uncheck that.
You can set default language by click on star in Polylang 'Languages' page, there will be a star for default language when someone is visiting your website. Also, don't forget to deactivate detect browser language in Polylang 'Settings' page, I hope this will work.
This works fine for me.
this solution isn't standard! but work for me :)
replace (comment) this line in wp-content/plugins/polylang/frontend/choose-lang.php file (line 185)
$language = $this->options['hide_default'] && ( ( isset( $_SERVER['HTTP_REFERER'] ) && in_array( parse_url( $_SERVER['HTTP_REFERER'], PHP_URL_HOST ), $this->links_model->get_hosts() ) ) || ! $this->options['browser'] ) ?
$this->model->get_language( $this->options['default_lang'] ) :
$this->get_preferred_language(); // sets the language according to browser preference or default language
by
$language = 'fa';
This is not a perfect solution but works for me. Change the following line in wp-content/plugins/polylang/frontend/choose-lang.php (Line no 247):
$this->set_language( $language );
to:
$this->set_language( 'ar' ); //set defalt language name.
If someone still having this problem.
I had the same issue with Polylang. I was not able to switch back to English after switching to Arabic. The problem had the easiest solution though. It appeared I forgot to set Site Language of WP itself in Settings>General as English UK (it was set to English US). After I changed that all worked fine.
ok i have solution. not need any code. when you set default language then need to go settings - than - URL modifications settings and mark first (The language is set from content) enter image description here
is someone have still problem with this, i found solution.
Go to DB > ptqsln_options (you have maybe different prefix) > polylang and at end of json is default_lang and change to your language. It works for me.
I had the same issue. My site was built in Mandarain first. Now, I'm adding English, but Polylang keeps saying the default is English and gives me tons of trouble when adding pages. I've figured out how to fix that.
Go to Language Settings, add the correct "default" language. In my case, Chinese. And double click it then you will see a star on it.
You will also see a star on the first row, the English one, which attaches many pages. And it has a star. Double click to unstar it. Now Polylang will think your default will be the only option soon.
Delete the first English one, which has many pages linked to it. (There's no need to back up.) Don't worry, it won't delete any pages. At this time, you only have one language option for Polylang; in my case, Chinese.
Run the setup wizard again. And you will see Polyland says the site's default language is in Chinese. (Or your correct default one.) Congrats! Now finish the setup as normal.
Go back to the Languages, and add English or the correct intended language back. Then you will see this new English has 0 posts attached to it, and the correct Default Lan has all of the posts to it!
Go to Settings > General and change the Site Language to Farsi. That will change the language of the admin part.
Is this what you've been looking for?

Slider Revolution custom font display

I am trying to embed a custom font into a slide and not so sure why, it doesn't display correctly.
I've followed all these instructions, uploading the font kit on the server, modifying the url's, applying the css settings to custom css slider rev. field, calling the font type font-family: itsadzokeregular; into the Advance editor section but something is missing; the result is the same no matter what browser I'll use to open this page.
Can I have your support please, what did I do wrong?
Thank you,

How to change 'inherited' font families using the CSS style sheet

I am not a programmer. The language is foreign. I am creating a WordPress website. I created a child-theme.
I read the theme documentation. Understood very little.
sent an email to the theme owner. No answer (2 weeks ago)
searched the web - found many websites - i.e. http://www.w3schools.com/ - http://css-tricks.com/sans-serif/ & others - me, no speak the language. Can you place html code in a CSS file?
The child-theme consists of a new style.css file. The top section of the style.css file is what was needed to create the child-theme. Then there are color changes which I inserted & that has gone very well.
Changing the font family is confusing. Poking around the parent theme and also using 'Firebug' the font(s) seem(s) to be ('inherited'?). .genericon, 'Roboto Condensed', Sans-serif, Arimo, Arial and a few other standard MS Word fonts. I saw on the Google font site a couple of fonts I would prefer to use for my website.
How do I (or even can I) download the Google fonts to the Style.css file?
What do I need to insert in the child style.css file to override the parent fonts?
In case this is important, the theme has more than one template (PHP?) option. I am using W7 OS.
The Google Fonts site is really direct and helpful.
In your example, you mention Roboto. Here's the page for that font.
You would check the varieties of Roboto that you want to be able to use on your site under Step 1.
Step 2 allows you to select additional character sets -- for example if you were likely to be displaying text in Russian.
Step 3 gives you three ways to "enable" the font on your site. You'll be placing a line of code somewhere, telling users' browsers to go and get the font from Google when called for. The easiest way to do this is probably the #import option. Copy and paste the code under that tab into your style.css at the top (that's important -- it should go before any of the stuff describing the layout or type on your stylesheet). Your sub-theme likely has a bunch of other #import lines up there already.
Step 4 shows what specifically you need to tell your stylesheet to look for.
Good luck!
External style sheets have the highest hierarchy, so just specify your styles with the id, class or element name.
Google is your friend here.
To use google fonts, go to the google font page and search for your font with the search box on the left, then click add to collection. Once in your collection, go to your collection and click "use".
You should get an "#import()" code, place this at the top of your external sheet.

Wordpress and RTL

WordPress is so powerful.. but yet it is so weak with RTL Languages like Arabic and Hebrew...
I need to have the Front-End in Arabic and Admin area to stay in English and of course LTR..
If I use the Arabic version of WordPress. Everything including the admin area will be in Arabic and RTL. which will not be suitable at all.
In the same time. Visually editing an Arabic post should be in RTL while the HTML view should be LTR..
I can see that MU version on wordpress.com can have admin area in English while the frontend is in Arabic.
How to do that?
WordPress's back end can handle Arabic just fine, with both the editor and the database itself. If you want the front end to display in Arabic you'll need to use/develop a theme that uses Arabic.
If your blog is Arabic-only, you can add a CSS class to the div surrounding the post in the blog template file that sets the text-direction to ltr. If you use Arabic and English, you can set an if statement to decide what direction each post needs to be based on a custom field you add to the post from the back end.
The general steps to add RTL are:
Step 1 - Create the RTL CSS for Your Theme.
The first step is to create the CSS for displaying RTL languages correctly on your website. There are two methods for doing this. The first is to simply feed your existing stylesheet into a CSS RTL generator. This tool will examine your CSS and attempt to make a copy, but switching all the left and right alignments. This effectively creates a mirrored version of your website.
Step 2 - Ensure WordPress ‘Sees’ the RTL Styles.
If you’re using a CSS generator tool, you’ll now need to enqueue your new style-rtl.css stylesheet so WordPress can load it in at the appropriate time. This is just a matter of adding a snippet to your theme’s functions.php file.
Step 3: Test Your RTL Styles in WordPress RTL Tester plugin.
You have a few options for testing out RTL languages in your WordPress installation. The first is to simply switch WordPress to an RTL language. To do this, go to the Settings > General page in your WordPress dashboard. Then, select the first script language you see in the Language drop-down box
Here is a full guide: https://torquemag.io/2018/03/rtl-support-wordpress/
For a successfully RTL site example, check out this one.
If you have access to the file system where the site is hosted:
Go to ./wp-content/themes/{THEME_NAME}/.
Find the CSS files of both LTR and RTL (They may be named as "style.css" & "style-rtl.css", depending on the theme and if it supports RTL).
Rename them by switching their names.
This way RTL is only applied to the theme.
I had the same issue. The blog is in Arabic, and the admin back-end is in English.
If you are using Firefox, you can simply overcome this problem by clicking Switch Text Direction from the right-click menu on the TinyMCE.

Resources