{"id":16409584,"url":"https://github.com/pointybeard/saxon","last_synced_at":"2025-10-26T17:32:39.782Z","repository":{"id":66719090,"uuid":"240871106","full_name":"pointybeard/saxon","owner":"pointybeard","description":"A Symphony CMS (http://getsymphony.com) extension that adds Saxon/C (XSLT 3.0) processing capabilities","archived":false,"fork":false,"pushed_at":"2021-09-29T10:42:28.000Z","size":13,"stargazers_count":6,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-31T22:11:28.035Z","etag":null,"topics":["saxon","symphony","symphonycms","xslt","xslt-3"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pointybeard.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-02-16T10:22:29.000Z","updated_at":"2024-02-21T13:38:58.000Z","dependencies_parsed_at":"2023-04-13T03:32:05.141Z","dependency_job_id":null,"html_url":"https://github.com/pointybeard/saxon","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pointybeard%2Fsaxon","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pointybeard%2Fsaxon/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pointybeard%2Fsaxon/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pointybeard%2Fsaxon/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pointybeard","download_url":"https://codeload.github.com/pointybeard/saxon/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":238380590,"owners_count":19462398,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["saxon","symphony","symphonycms","xslt","xslt-3"],"created_at":"2024-10-11T06:20:30.040Z","updated_at":"2025-10-26T17:32:34.492Z","avatar_url":"https://github.com/pointybeard.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Saxon/C XSLT Processing Extension for Symphony CMS\n\n-   Version: 0.1.0\n-   Date: Feb 17 2020\n-   [Release notes](https://github.com/pointybeard/saxon/blob/master/CHANGELOG.md)\n-   [GitHub repository](https://github.com/pointybeard/saxon)\n\nA [Symphony CMS](http://getsymphony.com) that adds Saxon/C (XSLT 3.0) processing capabilities.\n\n### Requirements\n\nThis extension has the following requirements:\n\n- PHP7.3 or later\n- [Saxon-HE/C 1.1.2](http://www.saxonica.com/saxon-c/index.xml#archive)\n- [Symphony CMS 2.7.10 Extended](https://github.com/pointybeard/symphony-2/tree/2.7.10-extended) or [Extended Essentials](https://github.com/pointybeard/symphony-2/tree/2.7.10-extended-essentials)\n\n## Installation\n\nAdd it to the `/extensions` folder of your Symphony CMS installation, then enable it via \"System\" \u003e \"Extensions\".\n\nOnce installed, choose `Saxon/C (XSLT 3.0)` as your XSLT processor in \"System\" \u003e \"Preferences\".\n\n### Installing Symphony CMS (Extended)\n\nThis is an extension for [Symphony CMS (Extended)](https://github.com/pointybeard/symphony-2/tree/2.7.10-extended). Use the following git commands to switch your Symphony 2.7.10 installation to 2.7.10 Extended.\n\n```\ngit remote add pointybeard https://github.com/pointybeard/symphony-2.git\ngit fetch pointybeard\ngit checkout -b 2.7.10-extended pointybeard/2.7.10-extended\n```\n\n## Installing Saxon-HE/C\n\nPHP does not offer XSLT 3.0 processing out of the box. In order to run this processor, you will need to install the Saxon-HE/C version of [Saxon](http://www.saxonica.com/). Follow the these steps to get Saxon-HE/C running on your server and available to PHP.\n\nFor this setup, we will assume Linux 64-bit (`libsaxon-HEC-setup64-v1.2.1.zip`) which you can download from \u003chttp://www.saxonica.com/download/c.xml\u003e. Substitute the file name below for other systems and versions.\n\n1. Run the following commands on your server to build and install the Saxon module for PHP:\n\n```\ncd /usr/local\nwget -q \"http://www.saxonica.com/saxon-c/libsaxon-HEC-setup64-v1.1.2.zip\"\nunzip \"libsaxon-HEC-setup64-v1.1.2.zip\"\n./libsaxon-HEC-setup64-v1.1.2 -batch\n\nln -s \"/usr/local/Saxonica/Saxon-HEC1.1.2/libsaxonhec.so\" /usr/lib/libsaxonhec.so\nln -s \"/usr/local/Saxonica/Saxon-HEC1.1.2/rt\" /usr/lib/rt\n\nbash -c \"echo '# JetVM env path (required for Saxon)' \u003e /etc/ld.so.conf.d/jetvm.conf\"\nbash -c \"echo /usr/lib/rt/lib/amd64 \u003e\u003e /etc/ld.so.conf.d/jetvm.conf\"\nbash -c \"echo /usr/lib/rt/lib/amd64/jetvm \u003e\u003e /etc/ld.so.conf.d/jetvm.conf\"\nldconfig\n\ncd \"/usr/local/Saxonica/Saxon-HEC1.1.2/Saxon.C.API/\"\n/usr/bin/phpize\n./configure --enable-saxon\nmake\nmake install\n\nbash -c \"echo env[LD_LIBRARY_PATH] = /usr/lib/rt/lib/amd64:/usr/lib/rt/lib/amd64/jetvm \u003e /etc/php/7.4/apache2/conf.d/saxon_ld_library_path.conf\"\nbash -c \"echo extension=saxon.so \u003e /etc/php/7.4/apache2/conf.d/20-saxon.ini\"\n\ncd \"/etc/php/7.4/apache2/conf.d/\"\nmv 20-saxon.ini \"/etc/php/7.4/mods-available/\"\nmv \"/etc/php/7.4/mods-available/20-saxon.ini\" \"/etc/php/7.4/mods-available/saxon.ini\"\n```\n\n2. Enable Saxon with the following command:\n\n`phpenmod saxon`\n\n3. Check it is enabled and working correctly with the following:\n\n`php -i | grep Saxon`\n`php -r '$proc = new Saxon\\SaxonProcessor(); var_dump($proc); echo $proc-\u003eversion();'`\n\n## Usage\n\nThe way page XSL is written is not different, however, developers get access to the newer features of XSLT (2.0 and onwards). You can read about some of the changes and benefits to using XSLT 3.0 here \u003chttps://www.xml.com/articles/2017/02/14/why-you-should-be-using-xslt-30/\u003e.\n\n### Current Limitations\n\nSaxon/C has a few minor differences in how it compiles XSL which will impact how you construct your pages.\n\n1. **Automatic Declaration of Parameters** -- Previously, all page parameters were avaialble automatically as xsl params. E.g. `$root`, and `$current-page` as well as in the XML itself (e.g. `/data/params/root`). There was no need to explicltly declare these via `xsl:param`. This has changed and any parameters being used that are provided by Symphony will need to be declared first (e.g. `\u003cxsl:param name=\"root\"/\u003e`) otherwise you will get an error.\n\n2. **Arrays of values in page parameters** -- Ordinarily, arrays of values (for example, Data source param output) was available in both the XML (i.e. `/data/params`) and as declared params (e.g. `$page-types`). Due to a bug in the Saxon/C binary for PHP, attempting to include such params automatically as a parameter causes Saxon to crash. As a result, any params that are arrays will ONLY be available via the XML.\n\n## Support\n\nIf you believe you have found a bug, please report it using the [GitHub issue tracker](https://github.com/pointybeard/saxon/issues),\nor better yet, fork the library and submit a pull request.\n\n## Contributing\n\nWe encourage you to contribute to this project. Please check out the [Contributing documentation](https://github.com/pointybeard/saxon/blob/master/CONTRIBUTING.md) for guidelines about how to get involved.\n\n## License\n\n\"Saxon/C XSLT Processing Extension for Symphony CMS\" is released under the [MIT License](http://www.opensource.org/licenses/MIT).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpointybeard%2Fsaxon","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpointybeard%2Fsaxon","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpointybeard%2Fsaxon/lists"}