PHPackages                             oeuvres/xsl - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. oeuvres/xsl

ActiveLibrary[Parsing &amp; Serialization](/categories/parsing)

oeuvres/xsl
===========

XSLT-1.0 package to transform texts, from and to, TEI

01871XSLTCI passing

Since Jun 25Pushed 1w ago3 watchersCompare

[ Source](https://github.com/oeuvres/teinte-xsl)[ Packagist](https://packagist.org/packages/oeuvres/xsl)[ RSS](/packages/oeuvres-xsl/feed)WikiDiscussions main Synced today

READMEChangelogDependenciesVersions (1)Used By (0)

Teinte, TEI shades, XSL pack
============================

[](#teinte-tei-shades-xsl-pack)

[teinte\_xsl](https://github.com/oeuvres/teinte_xsl/) is an XSLT-1.0 pack to transform XML texts, from, and to, different formats. The pivot format is a subset of [TEI](https://tei-c.org/release/docs/tei-p5-docs/en/html/REF-ELEMENTS.html), an academic XML schema dedicated to all forms of texts. Some formats have a complex packaging (docx, epub…). Such agregations requires another programation language for file manipulation or zipping (php, java, python…), but some results are already possible with xslt only, see below for browser or command line.

[![Teinte xsl graph](https://camo.githubusercontent.com/94fd7d9c11181b4d0220ef5524268f9e22da229d0f1da3b4b195abc169db4f6b/68747470733a2f2f6f6575767265732e6769746875622e696f2f7465696e74652f646f63732f7465696e74655f78736c2e706e67)](https://camo.githubusercontent.com/94fd7d9c11181b4d0220ef5524268f9e22da229d0f1da3b4b195abc169db4f6b/68747470733a2f2f6f6575767265732e6769746875622e696f2f7465696e74652f646f63732f7465696e74655f78736c2e706e67)

This pack is compatible with xsltproc and other XSLT engines. Tested with

- PHP: [teinte\_php](https://github.com/oeuvres/teinte_php)
- Java: [alix](https://github.com/oeuvres/alix)
- Javascript: direct transformation in browser (see below)
- Bash: (see below)
- Python: a command line pilot for Python is planned, needs support [teinte\_py](https://github.com/oeuvres/teinte_py)

Browser
=======

[](#browser)

All modern browsers have the xsltproc library embedded. This allows to provide direct transformation in the browser. See this [example XML file](https://oeuvres.github.io/teinte/examples/moliere_misanthrope.xml) under a web server, you should see a nicely formatted theatre play, even if it’s an [XML/TEI source](https://github.com/oeuvres/teinte/blob/main/examples/moliere_misanthrope.xml).

[![Misanthrope](https://camo.githubusercontent.com/beaa06acd8a5e2c07a102377491dcd3cfe3c888764bf873b36e499c5c6ad3d6f/68747470733a2f2f6f6575767265732e6769746875622e696f2f7465696e74652f646f63732f73637265656e732f2f7465696e74655f6d6973616e7468726f70652e706e67)](https://camo.githubusercontent.com/beaa06acd8a5e2c07a102377491dcd3cfe3c888764bf873b36e499c5c6ad3d6f/68747470733a2f2f6f6575767265732e6769746875622e696f2f7465696e74652f646f63732f73637265656e732f2f7465696e74655f6d6973616e7468726f70652e706e67)

The magic rely on the XML prolog of the file

```

```

This can be added to all TEI files to provide instant formatting online.

Offline, this feature is blocked for security reasons, see for example (image below) the result and the reason on the Google LLC proprietary browser. The open source [Firefox](https://www.mozilla.org/fr/firefox/new/) browser offers a workaround to bypass this security setting (list below). This little manipulation is done for ever, is reversible, is a lot less risky than javascript through the web, but industry has more interests in JS than XSLT. For a TEI editor, this allows to see the results of its XML modifications by a simple reload in the browser.

[![Google.LLC.Chrome fileuri](https://camo.githubusercontent.com/3710b31c2452ffc385bc4b13ac9e21d0a0d708c3ad58da2eee17c6b3ce7a0231/68747470733a2f2f6f6575767265732e6769746875622e696f2f7465696e74652f646f63732f73637265656e732f6368726f6d655f66696c657572692e706e67)](https://camo.githubusercontent.com/3710b31c2452ffc385bc4b13ac9e21d0a0d708c3ad58da2eee17c6b3ce7a0231/68747470733a2f2f6f6575767265732e6769746875622e696f2f7465696e74652f646f63732f73637265656e732f6368726f6d655f66696c657572692e706e67)

1. Firefox browser, in address bar, type `about:config`
2. accept security alert
3. search for the property: security.fileuri.strict\_origin\_policy
4. set to false

[![Firefox fileuri](https://camo.githubusercontent.com/6a95b7e543254e845d54e67a491ede5e8274515b99e610da0e73531f0b25acdb/68747470733a2f2f6f6575767265732e6769746875622e696f2f7465696e74652f646f63732f73637265656e732f66697265666f785f66696c657572692e706e67)](https://camo.githubusercontent.com/6a95b7e543254e845d54e67a491ede5e8274515b99e610da0e73531f0b25acdb/68747470733a2f2f6f6575767265732e6769746875622e696f2f7465696e74652f646f63732f73637265656e732f66697265666f785f66696c657572692e706e67)

Bash
====

[](#bash)

Under a linux box, or with a [WSL linux](https://ubuntu.com/wsl) on Microsoft.Windows, install xsltproc, and tranform your files.

```
sudo apt install xsltproc
cd teinte_xsl
xsltproc tei2html.xsl tests/moliere_misanthrope.xml
```

###  Health Score

24

—

LowBetter than 31% of packages

Maintenance64

Regular maintenance activity

Popularity12

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity11

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/5686231?v=4)[Frédéric Glorieux](/maintainers/glorieux-f)[@glorieux-f](https://github.com/glorieux-f)

---

Top Contributors

[![glorieux-f](https://avatars.githubusercontent.com/u/5686231?v=4)](https://github.com/glorieux-f "glorieux-f (280 commits)")

### Embed Badge

![Health badge](/badges/oeuvres-xsl/health.svg)

```
[![Health](https://phpackages.com/badges/oeuvres-xsl/health.svg)](https://phpackages.com/packages/oeuvres-xsl)
```

###  Alternatives

[mck89/peast

Peast is PHP library that generates AST for JavaScript code

19139.2M47](/packages/mck89-peast)[sauladam/shipment-tracker

Parses tracking information for several carriers, like UPS, USPS, DHL and GLS by simply scraping the data. No need for any kind of API access.

9843.5k](/packages/sauladam-shipment-tracker)[jstewmc/rtf

Read and write Rich Text Format (RTF) documents with PHP

45153.1k6](/packages/jstewmc-rtf)[tcds-io/php-jackson

A lightweight, flexible object serializer for PHP, inspired by FasterXML/jackson

113.2k10](/packages/tcds-io-php-jackson)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
