Php Xliff (xliff, xlf)

PHP XLIFF format uses the XLIFF XML standard for PHP application localization. Symfony's translation component natively supports XLIFF alongside YAML and PHP arrays. XLIFF provides a richer structure than flat PHP arrays with support for translation state tracking, notes, and the industry-standard format that professional CAT tools expect.

PHP XLIFF files follow the XLIFF 1.2 or 2.0 specification. Translation units contain source and target elements for the original and translated strings. Notes elements provide translator context. The resname attribute identifies the logical key name used in PHP code. Translation status is tracked using the state element, which CAT tools use to determine whether a string needs translation or review.

Best practice: use XLIFF when working with professional translation agencies that use CAT tools — XLIFF is industry-standard and compatible with most professional translation environments. Write notes for every string with context-dependent meaning. Language Monster supports PHP XLIFF format and handles both XLIFF 1.2 and XLIFF 2.0 file structures.

Read More File Formats