Skip to content

Commit 6f26e28

Browse files
committed
Many language support has been added.
1 parent 1014504 commit 6f26e28

22 files changed

+243
-24
lines changed

about.php

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22

33
/**
44
** about.php
5-
** @version 1.0
5+
** @version 1.0.1
6+
** @since 1.0
67
** @author en0ndev
78
*/
89
/*
@@ -24,10 +25,10 @@
2425
defined('ABSPATH') || exit; // Exit if accessed directly
2526

2627
$template = "<div class='about'><p class='big'>Custom Profile Avatar</p>";
27-
$template .= "<p>Version: 1.0</p>";
28-
$template .= "<p>Developer: en0ndev</p>";
29-
$template .= "<a class='link' target='_blank' href='https://www.youtube.com/channel/UC3CSOAThanO-LvYKFwJ24RQ'>My YouTube Channel</a></div>";
28+
$template .= "<p>" . esc_html__('Version', 'custom-profile-avatar') . ": 1.0.1</p>";
29+
$template .= "<p>" . esc_html__('Developer', 'custom-profile-avatar') . ": en0ndev</p>";
30+
$template .= "<a class='link' target='_blank' href='https://www.youtube.com/channel/UC3CSOAThanO-LvYKFwJ24RQ'>" . esc_html__('My YouTube Channel', 'custom-profile-avatar') . "</a></div>";
3031

3132
$page = new cpa__page__template;
3233

33-
$page->cpa__get__template("About", $template, 0);
34+
$page->cpa__get__template(__('About', 'custom-profile-avatar'), $template, 0);

assets/css/style.css

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
/**
22
** File: style.css
3-
** Version: 1.0
3+
** Version: 1.0.1
4+
** Since: 1.0
45
** Author: en0ndev
56
67
This file is part of Custom Profile Avatar.

assets/js/modules.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
/**
22
** File: modules.js
3-
** Version: 1.0
3+
** Version: 1.0.1
4+
** Since: 1.0
45
** Author: en0ndev
56
This file is part of Custom Profile Avatar.
67

index.php

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,10 @@
44
Plugin Name: Custom Profile Avatar
55
Plugin URI: https://wordpress.org/plugins/custom-profile-avatar
66
Description: Change profile avatar to your custom avatar.
7-
Version: 1.0
7+
Version: 1.0.1
88
Author: en0ndev
99
Author URI: https://github.com/en0ndev
10+
Text Domain: custom-profile-avatar
1011
1112
This file is part of Custom Profile Avatar.
1213
@@ -30,3 +31,9 @@
3031
require_once __DIR__ . '/modules/template.php';
3132
require_once __DIR__ . '/modules/get_avatar.php';
3233
require_once __DIR__ . '/modules/get_styles.php';
34+
35+
function cpa_load_textdomain()
36+
{
37+
load_plugin_textdomain('custom-profile-avatar', false, basename(dirname(__FILE__)) . '/languages/');
38+
}
39+
add_action('plugins_loaded', 'cpa_load_textdomain');
736 Bytes
Binary file not shown.
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# Copyright (C) 2021 by the contributors
2+
# This file is distributed under the same license as the WordPress package.
3+
msgid ""
4+
msgstr ""
5+
"Project-Id-Version: Custom Profile Avatar 1.0.1\n"
6+
"Report-Msgid-Bugs-To: \n"
7+
"Language-Team: \n"
8+
"MIME-Version: 1.0\n"
9+
"Content-Type: text/plain; charset=UTF-8\n"
10+
"Content-Transfer-Encoding: 8bit\n"
11+
"POT-Creation-Date: 2021-03-24 22:06+0300\n"
12+
"PO-Revision-Date: 2021-03-25 15:55+0300\n"
13+
"X-Generator: Poedit 2.4.2\n"
14+
"Last-Translator: \n"
15+
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
16+
"Language: de_DE\n"
17+
18+
msgid "Settings"
19+
msgstr "Einstellungen"
20+
21+
msgid "Save"
22+
msgstr "Speichern"
23+
24+
msgid "Change Avatar"
25+
msgstr "Avatar ändern"
26+
27+
msgid "About"
28+
msgstr "Über"
29+
30+
msgid "Version"
31+
msgstr "Version"
32+
33+
msgid "Developer"
34+
msgstr "Entwickler"
35+
36+
msgid "My YouTube Channel"
37+
msgstr "Mein YouTube-Kanal"
38+
39+
msgid "Developed by"
40+
msgstr "Plugin entwickelt von:"
744 Bytes
Binary file not shown.
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# Copyright (C) 2021 by the contributors
2+
# This file is distributed under the same license as the WordPress package.
3+
msgid ""
4+
msgstr ""
5+
"Project-Id-Version: Custom Profile Avatar 1.0.1\n"
6+
"Report-Msgid-Bugs-To: \n"
7+
"Language-Team: \n"
8+
"MIME-Version: 1.0\n"
9+
"Content-Type: text/plain; charset=UTF-8\n"
10+
"Content-Transfer-Encoding: 8bit\n"
11+
"POT-Creation-Date: 2021-03-24 22:06+0300\n"
12+
"PO-Revision-Date: 2021-03-25 15:57+0300\n"
13+
"X-Generator: Poedit 2.4.2\n"
14+
"Last-Translator: \n"
15+
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
16+
"Language: fr_FR\n"
17+
18+
msgid "Settings"
19+
msgstr "Paramètres"
20+
21+
msgid "Save"
22+
msgstr "Sauvegarder"
23+
24+
msgid "Change Avatar"
25+
msgstr "Changer l'avatar"
26+
27+
msgid "About"
28+
msgstr "À propos"
29+
30+
msgid "Version"
31+
msgstr "Version"
32+
33+
msgid "Developer"
34+
msgstr "Développeur"
35+
36+
msgid "My YouTube Channel"
37+
msgstr "Ma chaîne YouTube"
38+
39+
msgid "Developed by"
40+
msgstr "Plugin développé par:"
736 Bytes
Binary file not shown.
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# Copyright (C) 2021 by the contributors
2+
# This file is distributed under the same license as the WordPress package.
3+
msgid ""
4+
msgstr ""
5+
"Project-Id-Version: Custom Profile Avatar 1.0.1\n"
6+
"Report-Msgid-Bugs-To: \n"
7+
"Language-Team: \n"
8+
"MIME-Version: 1.0\n"
9+
"Content-Type: text/plain; charset=UTF-8\n"
10+
"Content-Transfer-Encoding: 8bit\n"
11+
"POT-Creation-Date: 2021-03-24 22:06+0300\n"
12+
"PO-Revision-Date: 2021-03-25 15:59+0300\n"
13+
"X-Generator: Poedit 2.4.2\n"
14+
"Last-Translator: \n"
15+
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
16+
"Language: it_IT\n"
17+
18+
msgid "Settings"
19+
msgstr "Impostazioni"
20+
21+
msgid "Save"
22+
msgstr "Salvare"
23+
24+
msgid "Change Avatar"
25+
msgstr "Cambia Avatar"
26+
27+
msgid "About"
28+
msgstr "Info"
29+
30+
msgid "Version"
31+
msgstr "Versione"
32+
33+
msgid "Developer"
34+
msgstr "Sviluppatore"
35+
36+
msgid "My YouTube Channel"
37+
msgstr "Il mio canale YouTube"
38+
39+
msgid "Developed by"
40+
msgstr "Plugin sviluppato da:"

0 commit comments

Comments
 (0)