Support for DeepL tag_handling option

Created on 24 April 2025, 16 days ago

Problem/Motivation

With the default settings DeepL doesn't take HTML tags into account and will return broken HTML.

Proposed resolution

DeepL has a option to enable tag handling for HTML or XML:

https://developers.deepl.com/docs/xml-and-html-handling/html

It would be awesome to have an option to enable it within the DeepL settings form.

I believe it's possible to do something like:

$options = [
  'tag_handling' => 'html',
];
try {
  $result = $translator->translateText($text, $from, $to, $options);
}
Feature request
Status

Active

Version

1.0

Component

Code

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024