WPtouch in french – Update 1.9.5
The translation for the WPtouch 1.9.5 update is available ! You can download the language file.
The translation for the WPtouch 1.9.5 update is available ! You can download the language file.
A little tip to secure your WordPress blog (you can use it with another CMS indeed) : just put a .htaccess into you admin folder : for WordPress it’s in wp-admin
Example .htaccess
AuthUserFile /dev/null AuthGroupFile /dev/null AuthName "Access Control" AuthType Basic <LIMIT GET> order deny,allow deny from all # whitelist home IP address allow from my.ip.at.home # whitelist work IP address allow from my.ip.at.work </LIMIT>
And of course, you change this file with your own IP addresses…
If you are using WordPress and the WPML plugin to manage your web site in multi language, you have surely noticed that when a visitor uses the search engine, WordPress displays the result list of the default language and not of the language currently used by the visitor…
To upgrade this feature, I’ve done a little patch… It’s a quick and dirty one but it works (you can easily optimise this by using a function to overload the default behavior of WordPress instead of directly modifying the standard WordPress files (and loosing your modification during the next upgrade…)
Update the file wp-includes/general-template.php for the function get_bloginfo like this :
case 'short_language':
$output = get_locale();
$short_language = explode("_", $output);
$output = $short_language[0];
break;
And the on your theme (e.g. iNove in wp-content/themes/inove/templates/header.php file) :
You just have to modify the form like this :
<form action="<?php bloginfo('home'); ?>/<?php bloginfo('short_language'); ?>/"
method="get">
Have fun with WordPress and WPML !
ps : you can also modify the links to your title/home to avoid switching language when a user click on the logo
<h1 id="title">
<a href="<?php bloginfo('url'); ?>/<?php bloginfo('short_language'); ?>/">
<?php bloginfo('name'); ?>
</a>
</h1>
and for the breadcrumbs…
<a title="<?php _e('Home', 'inove'); ?>"
href="<?php echo get_settings('home'); ?>/<?php bloginfo('short_language'); ?>/">
<?php _e('Home', 'inove'); ?>
</a>
By the way, the idea comes from this thread…
If, like me, you are using WPtouch to manage the display of your web site in “iPhone mode”… You can use the french translation I did.
You have just to add this code in the beginning of your wptouch.php file under the line
define( 'WPTOUCH_PROWL_APPNAME', 'WPtouch');
/** l10n */
function wptouch_plugin_localization(){
load_plugin_textdomain('wptouch', false, 'wptouch/locale');
}
add_action ('init', 'wptouch_plugin_localization');
And then unzip the translation file for WPtouch 1.9.19.14 into your wptouch/locale folder.
You should have the following treeview :
./wptouch/locale
./wptouch/locale/wptouch-fr_FR.mo
./wptouch/locale/wptouch-fr_FR.po
That’s all folks
The frontoffice and backoffice side of this plugin are then translated in french.
You can use this “addon” for free, don’t hesitate to upgrade it or send me a comment !
See alse :