Add translation file for Wordpress theme. Function open

Add translation file for Wordpress theme. Function

After adding your translation files to yourthemename/lang folder

You need to attach a translation file for your theme

Add the code below to your function.php file. Don’t forget to change the theme_name

function exemple_function () {
    load_theme_textdomain('theme_name', get_template_directory() . '/lang')
}
add_action('after_setup_theme', 'exemple_function', 0 )
0

More

Leave a Reply

Your email address will not be published. Required fields are marked *

How many?: 22 + 22

lil-code© | 2022 - 2024
Go Top
Authorization
*
*
Registration
*
*
*
*
Password generation