Quote:
Originally Posted by NLP-er
Hello right now google translates non braking spaces to normal spaces what can damage some layouts. To change this behaviour edit vb Global Translator hook
and replace:
Code:
require_once("translate.php");
$output=callback($output);
to:
Code:
$output = str_replace(" ", "< >", $output);
require_once("translate.php");
$output=callback($output);
$output = str_replace("< >", " ", $output);
Thanks 
|
Because it was not included in official release once again I strongly reccomend to made this change and also execute those queries on DB:
Code:
delete from wt_cache_short where originaltext like '% %';
delete from wt_cache_medium where originaltext like '% %';
delete from wt_cache where originaltext like '% %';
Other wise it is possible that your cache will be populated by data like
X
X
X
So for same X translation you can have many data in DB. Making mentioned change makes it works faster, and DB is smaller. Also executing those queries on DB will remove all data like listed above and bellow, X will be translated again and after that work without dummy DB filling, and unnecessary querying google for translations. Also indexes should be smaller and faster because there is less common prefixes in originaltext.
Also in my forum many sites have translations like:
Posts: X Y
So now you have translations like i.e.
Posts: 1 213
Posts: 1 6
Posts: 2 213
Posts: 2 6
Posts: 1 100
Posts: 2 100
Posts: 3 100
Posts: 3 213
Posts: 3 6
After my changes you will have less translations. For mentioned examples it will be only:
Posts: 1
Posts: 2
Posts: 3
213
100
6
Once again - I advice those changes