Translate WordPress with GTranslate - Version 2.8.43

Version Description

  • New features in User Dashboard:
  • Find and Replace before and after translation
  • Skip Translation of Phrases
  • Skip Translation by CSS selector
  • Skip Translation by page URL
  • Define HTML Blocks to edit translation as a whole
  • Define JSON object keys which should be translated
  • Optimized translation of URL slugs
  • Fix for Sundanese flag
  • Fix for double language code when redirection happens based on referrer
Download this release

Release Info

Developer edo888
Plugin Icon 128x128 Translate WordPress with GTranslate
Version 2.8.43
Comparing to
See all releases

Code changes from version 2.8.42 to 2.8.43

24/su.png CHANGED
Binary file
flags/16/su.png CHANGED
Binary file
flags/24/su.png CHANGED
Binary file
flags/32/su.png CHANGED
Binary file
flags/48/su.png CHANGED
Binary file
gtranslate.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: GTranslate
4
  Plugin URI: https://gtranslate.io/?xyz=998
5
  Description: Makes your website <strong>multilingual</strong> and available to the world using Google Translate. For support visit <a href="https://wordpress.org/support/plugin/gtranslate">GTranslate Support</a>.
6
- Version: 2.8.42
7
  Author: Translate AI Multilingual Solutions
8
  Author URI: https://gtranslate.io
9
  Text Domain: gtranslate
@@ -2053,6 +2053,10 @@ if($data['pro_version'] or $data['enterprise_version']) {
2053
  'wc-country-select',
2054
  'wc-add-to-cart',
2055
  'wc-password-strength-meter',
 
 
 
 
2056
 
2057
  );
2058
 
3
  Plugin Name: GTranslate
4
  Plugin URI: https://gtranslate.io/?xyz=998
5
  Description: Makes your website <strong>multilingual</strong> and available to the world using Google Translate. For support visit <a href="https://wordpress.org/support/plugin/gtranslate">GTranslate Support</a>.
6
+ Version: 2.8.43
7
  Author: Translate AI Multilingual Solutions
8
  Author URI: https://gtranslate.io
9
  Text Domain: gtranslate
2053
  'wc-country-select',
2054
  'wc-add-to-cart',
2055
  'wc-password-strength-meter',
2056
+ 'googlecode_regular',
2057
+ 'googlecode_property',
2058
+ 'googlecode_contact',
2059
+ 'mapfunctions',
2060
 
2061
  );
2062
 
readme.txt CHANGED
@@ -4,7 +4,7 @@ Author: Translate AI Multilingual Solutions
4
  Tags: translate wordpress, multilingual, translate, translation, language, bilingual, localization, translation proxy, i18n, l10n, localisation, multilanguage, google translate
5
  Requires at least: 2.8.1
6
  Tested up to: 4.9
7
- Stable tag: 2.8.42
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
  Donate link: https://gtranslate.io/?xyz=998#pricing
@@ -218,8 +218,21 @@ You need to go to the language you want to edit, for instance, French: http://do
218
  5. Flags with language names
219
  6. Flags with language codes
220
  7. Settings page
 
221
 
222
  == Changelog ==
 
 
 
 
 
 
 
 
 
 
 
 
223
  = 2.8.42 =
224
  * New dashboard for paid customers https://my.gtranslate.io/
225
  * Minor changes
4
  Tags: translate wordpress, multilingual, translate, translation, language, bilingual, localization, translation proxy, i18n, l10n, localisation, multilanguage, google translate
5
  Requires at least: 2.8.1
6
  Tested up to: 4.9
7
+ Stable tag: 2.8.43
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
  Donate link: https://gtranslate.io/?xyz=998#pricing
218
  5. Flags with language names
219
  6. Flags with language codes
220
  7. Settings page
221
+ 8. User Dashboard
222
 
223
  == Changelog ==
224
+ = 2.8.43 =
225
+ * New features in User Dashboard:
226
+ * Find and Replace before and after translation
227
+ * Skip Translation of Phrases
228
+ * Skip Translation by CSS selector
229
+ * Skip Translation by page URL
230
+ * Define HTML Blocks to edit translation as a whole
231
+ * Define JSON object keys which should be translated
232
+ * Optimized translation of URL slugs
233
+ * Fix for Sundanese flag
234
+ * Fix for double language code when redirection happens based on referrer
235
+
236
  = 2.8.42 =
237
  * New dashboard for paid customers https://my.gtranslate.io/
238
  * Minor changes
url_addon/gtranslate.php CHANGED
@@ -122,6 +122,7 @@ curl_setopt($ch, CURLOPT_URL, $page_url);
122
  curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
123
  curl_setopt($ch, CURLOPT_HEADER, true);
124
  curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
 
125
  curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
126
  curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 2);
127
 
@@ -198,6 +199,7 @@ foreach($response_headers as $header) {
198
  if(preg_match('/^Location:/i', $header)) {
199
  $header = str_ireplace($host, $_SERVER['HTTP_HOST'] . '/' . $glang, $header);
200
  $header = str_ireplace('Location: /', 'Location: /' . $glang . '/', $header);
 
201
  }
202
 
203
  // woocommerce cookie path fix
122
  curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
123
  curl_setopt($ch, CURLOPT_HEADER, true);
124
  curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
125
+ //curl_setopt($ch, CURLOPT_SSLVERSION, CURL_SSLVERSION_TLSv1_2);
126
  curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
127
  curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 2);
128
 
199
  if(preg_match('/^Location:/i', $header)) {
200
  $header = str_ireplace($host, $_SERVER['HTTP_HOST'] . '/' . $glang, $header);
201
  $header = str_ireplace('Location: /', 'Location: /' . $glang . '/', $header);
202
+ $header = str_replace('/' . $glang . '/' . $glang . '/', '/' . $glang . '/', $header);
203
  }
204
 
205
  // woocommerce cookie path fix
url_addon/rewrite.txt CHANGED
@@ -1,5 +1,4 @@
1
  ### BEGIN GTranslate config ###
2
- RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
3
  RewriteRule ^(af|sq|am|ar|hy|az|eu|be|bn|bs|bg|ca|ceb|ny|zh-CN|zh-TW|co|hr|cs|da|nl|en|eo|et|tl|fi|fr|fy|gl|ka|de|el|gu|ht|ha|haw|iw|hi|hmn|hu|is|ig|id|ga|it|ja|jw|kn|kk|km|ko|ku|ky|lo|la|lv|lt|lb|mk|mg|ms|ml|mt|mi|mr|mn|my|ne|no|ps|fa|pl|pt|pa|ro|ru|sm|gd|sr|st|sn|sd|si|sk|sl|so|es|su|sw|sv|tg|ta|te|th|tr|uk|ur|uz|vi|cy|xh|yi|yo|zu)/(af|sq|am|ar|hy|az|eu|be|bn|bs|bg|ca|ceb|ny|zh-CN|zh-TW|co|hr|cs|da|nl|en|eo|et|tl|fi|fr|fy|gl|ka|de|el|gu|ht|ha|haw|iw|hi|hmn|hu|is|ig|id|ga|it|ja|jw|kn|kk|km|ko|ku|ky|lo|la|lv|lt|lb|mk|mg|ms|ml|mt|mi|mr|mn|my|ne|no|ps|fa|pl|pt|pa|ro|ru|sm|gd|sr|st|sn|sd|si|sk|sl|so|es|su|sw|sv|tg|ta|te|th|tr|uk|ur|uz|vi|cy|xh|yi|yo|zu)/(.*)$ /$1/$3 [R=301,L]
4
  RewriteCond %{REQUEST_FILENAME} !-f
5
  RewriteRule ^(af|sq|am|ar|hy|az|eu|be|bn|bs|bg|ca|ceb|ny|zh-CN|zh-TW|co|hr|cs|da|nl|en|eo|et|tl|fi|fr|fy|gl|ka|de|el|gu|ht|ha|haw|iw|hi|hmn|hu|is|ig|id|ga|it|ja|jw|kn|kk|km|ko|ku|ky|lo|la|lv|lt|lb|mk|mg|ms|ml|mt|mi|mr|mn|my|ne|no|ps|fa|pl|pt|pa|ro|ru|sm|gd|sr|st|sn|sd|si|sk|sl|so|es|su|sw|sv|tg|ta|te|th|tr|uk|ur|uz|vi|cy|xh|yi|yo|zu)/(.*)$ GTRANSLATE_PLUGIN_PATH/url_addon/gtranslate.php?glang=$1&gurl=$2 [L,QSA]
1
  ### BEGIN GTranslate config ###
 
2
  RewriteRule ^(af|sq|am|ar|hy|az|eu|be|bn|bs|bg|ca|ceb|ny|zh-CN|zh-TW|co|hr|cs|da|nl|en|eo|et|tl|fi|fr|fy|gl|ka|de|el|gu|ht|ha|haw|iw|hi|hmn|hu|is|ig|id|ga|it|ja|jw|kn|kk|km|ko|ku|ky|lo|la|lv|lt|lb|mk|mg|ms|ml|mt|mi|mr|mn|my|ne|no|ps|fa|pl|pt|pa|ro|ru|sm|gd|sr|st|sn|sd|si|sk|sl|so|es|su|sw|sv|tg|ta|te|th|tr|uk|ur|uz|vi|cy|xh|yi|yo|zu)/(af|sq|am|ar|hy|az|eu|be|bn|bs|bg|ca|ceb|ny|zh-CN|zh-TW|co|hr|cs|da|nl|en|eo|et|tl|fi|fr|fy|gl|ka|de|el|gu|ht|ha|haw|iw|hi|hmn|hu|is|ig|id|ga|it|ja|jw|kn|kk|km|ko|ku|ky|lo|la|lv|lt|lb|mk|mg|ms|ml|mt|mi|mr|mn|my|ne|no|ps|fa|pl|pt|pa|ro|ru|sm|gd|sr|st|sn|sd|si|sk|sl|so|es|su|sw|sv|tg|ta|te|th|tr|uk|ur|uz|vi|cy|xh|yi|yo|zu)/(.*)$ /$1/$3 [R=301,L]
3
  RewriteCond %{REQUEST_FILENAME} !-f
4
  RewriteRule ^(af|sq|am|ar|hy|az|eu|be|bn|bs|bg|ca|ceb|ny|zh-CN|zh-TW|co|hr|cs|da|nl|en|eo|et|tl|fi|fr|fy|gl|ka|de|el|gu|ht|ha|haw|iw|hi|hmn|hu|is|ig|id|ga|it|ja|jw|kn|kk|km|ko|ku|ky|lo|la|lv|lt|lb|mk|mg|ms|ml|mt|mi|mr|mn|my|ne|no|ps|fa|pl|pt|pa|ro|ru|sm|gd|sr|st|sn|sd|si|sk|sl|so|es|su|sw|sv|tg|ta|te|th|tr|uk|ur|uz|vi|cy|xh|yi|yo|zu)/(.*)$ GTRANSLATE_PLUGIN_PATH/url_addon/gtranslate.php?glang=$1&gurl=$2 [L,QSA]