WP Manifestindependent plugin directory
manifest / i18n / ducky-translator

Ducky Translator

Let Ducky handle your translations! A fun and efficient plugin that turns your WordPress site into a multilingual experience.

by Duckname · github.com/duckyname/ducky-translator · website

0stars
0forks

Install

No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:

wp plugin install https://github.com/duckyname/ducky-translator/archive/refs/heads/main.zip

Ducky Translator - Wordpress Plugin

A powerful WordPress plugin that provides real-time translation of your website content using the DeepL API. Translate your entire website into multiple languages with ease.

Features

  • 🌍 Multi-language Support - Support for 30+ languages
  • 🚀 Real-time Translation - Instant translation of all frontend content
  • 💾 Smart Caching - Translations are cached to save API quota and improve performance
  • 🎨 Flexible Display - Choose between flags only, text only, or flags + text
  • 🔒 Primary Language - Set your site's primary language that's always available
  • Fast Performance - Optimized batch translation with localStorage caching

Installation Guide

Step 1: Install the Plugin

  1. Download the plugin files
  2. Upload the ducky-translator folder to /wp-content/plugins/ directory
  3. Activate the plugin through the 'Plugins' menu in WordPress

Step 2: Register for DeepL API

  1. Go to DeepL API website
  2. Click on "Sign up" or "Get API key"
  3. Create a free account (DeepL offers a free tier with 500,000 characters per month)
  4. Complete the registration process
  5. Navigate to your DeepL account dashboard

Step 3: Get Your API Key

  1. In your DeepL account dashboard, find the "API keys" section
  2. Click on "Create API key" or "Generate new key"
  3. Copy your API key (it will look like: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx:fx for free tier)
  4. Important: Keep your API key secure and don't share it publicly

Step 4: Configure the Plugin

  1. Go to WordPress Admin → Settings → Ducky Translator
  2. Click on the "License Key" tab
  3. Paste your DeepL API key in the "DeepL API Key" field
  4. Click "Save Changes"
  5. Click "Test API Connection" to verify your API key is working correctly

Step 5: Set Up Languages

  1. In the "License Key" tab, set your "Primary Language" (the default language of your website)
  2. Go to the "Settings" tab
  3. Select the languages you want to make available for translation
  4. Choose your preferred display mode (Flags only, Text only, or Flags + Text)
  5. Click "Save Changes"

Step 6: Verify Installation

  1. Visit your website's frontend
  2. Look for the language selector in the bottom-left corner
  3. Select a different language to test the translation
  4. Your content should translate automatically

Requirements

  • WordPress 5.0 or higher
  • PHP 7.4 or higher
  • OpenSSL extension enabled (required for HTTPS API requests)
  • cURL extension (recommended, but not required)
  • allow_url_fopen enabled in php.ini (if cURL is not available)

Configuration

Primary Language

The primary language is your website's default language. This language:

  • Is always available in the language selector
  • Serves as the source language for all translations
  • Cannot be removed from available languages

Available Languages

Select which languages should be available for your visitors. The primary language is automatically included.

Display Mode

Choose how the language selector appears:

  • Flags + Text: Shows both flag icon and language name (default)
  • Flags Only: Shows only flag icons
  • Text Only: Shows only language names

Troubleshooting

Translation Not Working

  1. Check API Key: Ensure your DeepL API key is correctly entered in the License Key tab
  2. Test Connection: Use the "Test API Connection" button to verify your API key
  3. Check PHP Extensions: Ensure OpenSSL is enabled in your php.ini file
  4. Check Error Logs: Review WordPress error logs for detailed error messages

SSL/HTTPS Issues on Localhost

If you're running WordPress on localhost without SSL:

  • The plugin includes fallback methods for localhost environments
  • Ensure OpenSSL extension is enabled in php.ini
  • Check that allow_url_fopen is enabled

OpenSSL Not Loaded

If you see "OpenSSL Extension: NOT LOADED":

  1. Open your php.ini file
  2. Find the line: ;extension=openssl
  3. Remove the semicolon: extension=openssl
  4. Save the file and restart your web server

API Quota

DeepL Free tier includes:

  • 500,000 characters per month
  • Translations are cached for 30 days to minimize API usage
  • localStorage caching on the frontend for even better performance

Support

For issues, questions, or feature requests, please open an issue on GitHub.

License

This plugin is provided as-is for free use.

Changelog

1.0.0

  • Initial release
  • DeepL API integration
  • Multi-language support
  • Smart caching system
  • Flexible display options