Download the PHP package netzmacht/contao-i18n without Composer

On this page you can find all versions of the php package netzmacht/contao-i18n. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package contao-i18n

Contao I18n

Build Status Version License Downloads

This extension provides a flexible way for multilingual websites where parts of the main language should be reused on the translated pages.

Install

You can install this extension using Composer.

Requirements

Features

Language aware redirects

The main idea of the repository is you want to reuse modules or content from the main page in the translations. If you do so - most links or redirects would go back to the main language.

That's where this extension hook into. It detects references to pages in another language tree. If the it's the case it try to find the translation and manipulates the target page to the translation.

It works for all page references. No matter if you have a jumpTo in your form or module. But you stay in control. You can disable this behaviour by disable it in the page of the main language. Also the change language module is blacklisted, so you are still able to link to another language.

  1. Setup the pages and connect pages as usual with changelanguage.
  2. Set the redirect page to the fallback language.
  3. In you want to disable the "page translation" you may configure it in your page setting.

So you only have to define once the language relations! And you keep control if language redirects is required.

Same pages in different languages

Sometimes you have to translate your website but some pages stays identical. If you use different page aliases in your language tree the fallback page is not loaded.

The I18n Regular page is designed to solve this issue. It simply loads all the content of the fallback page. So it's possible to have language aware aliases but use same content without duplication.

On top of it the language is kept. This means that Contao uses the language defined in the page settings. This enables you to use insert tags to translate contents.

Same news, events and faqs in different languages

If you want to reuse news, events and faqs in different languages, it's supported. You only have to use the I18n Regular page as the reader page in the translation tree. This extension automatically creates the search page entries and sitemap entries for you.

Known limitation: The rss feed are not translated at the moment.

Translation insert tags

The two features above allow you to reduce the stupid duplication of modules or page when where is no difference. But sometimes some labels has to be translated as well.

Use the {{translate::*}} insert tag for this or even it's shortcut {{t::*}}.

Following syntax is supported:

{{t::path.to.translation}} Try to get the translation from the page_ALIAS domain. Fallback to website domain if not translated. If the page type is an i18n page type, the alias of the base page is used instead.

In other words, you have to create a page_ALIAS.php translation file. If you have website wide translations use the website.php language file.

If no page alias is given, the page id is used instead. Folder aliases get escaped to underscores.

{{t::domain:path.to.translation}} Translate from a custom domain.

Note: The dot syntax is used for the array structure of the language file. Note: Nested insert tags are supported in the translation strings.

Navigation modules

This extension provides two navigation modules which goes a step further. They does not only replace the url but the whole page. So you get an translated navigation module even if you have a reference page set in a navigation module or you use an individual navigation.

Configuration

By default, contao-i18n does not delete any articles in the contao i18n regular page. If they are not connected as page to override other pages, they are simply ignored. However, you can enable the cleanup. If cleanup is enabled all articles are deleted which are not configured as an article override.

Development

This repository contains a ddev configuration for a local test and development environment of this extension. It also provides a snapshot of the database. So it's easy to set up a local instance for yourself. For the general usage of ddev read the ddev documentation.

Following credentials are used:

Backend user

Install tool


All versions of contao-i18n with dependencies

PHP Build Version
Package Version
Requires php Version ^8.1
contao/core-bundle Version ^4.13
doctrine/dbal Version ^3.3
hofff/contao-root-relations Version ^3.0
menatwork/contao-multicolumnwizard-bundle Version ^3.5
netzmacht/contao-toolkit Version ^3.8
psr/log Version ^1.0 || ^2.0 || ^3.0
symfony/asset Version ^5.4
symfony/config Version ^5.4
symfony/dependency-injection Version ^5.4
symfony/http-foundation Version ^5.4
symfony/http-kernel Version ^5.4
symfony/translation-contracts Version ^2.3
terminal42/contao-changelanguage Version ^3.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package netzmacht/contao-i18n contains the following files

Loading the files please wait ....