Skip to main content

Add google translate to your website templates easily.

Project description

Google Translate provides easy way to add google translate plugin in your django templates. If your project needs to have multiple languages and if you dont want to manage .po files then you can add this package to make your website available in multiple languages easily without any hassle.

https://i.ibb.co/TK59rCp/Annotation-2020-06-27-124837.jpg
Simple
https://i.ibb.co/pwC7SJn/Annotation-2020-06-27-124803.jpg
Vertical
https://i.ibb.co/YcxND7v/Annotation-2020-06-27-124821.jpg
Horizontal

Quick start

  1. Download the package:

    pip install django-google-translate
  2. Add “google_translate” to your INSTALLED_APPS setting like this:

    INSTALLED_APPS = [
        ...
        'google_translate',
    ]
  3. Load the translate tag in your template (ideally on base.html):

    {% load google_translate %}
  4. Add following template tag wherever you want to show translate button:

    {% google_translate %}
  5. You can also pass type and default language in the translate button type in the inclusion tag (OPTIONAL):

    {% google_translate type='vertical' language='en' %}

Available values for the type are “horizontal”, “vertical” and “simple” (default) and for language you can pass any ISO language code

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-google-translate-1.1.tar.gz (4.0 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page