Skip to the content
Documentation
Help Start
Reading in:
  • German: 9,059 of 9,059 pages
About the help in other languages
All help pages

Part 4: Upgrading an old extension to Exponential 6

Part 4 of the book: bring an old extension up to Exponential 6, from the inventory and PHP 8 fixes to CSP, jQuery 4, admin4 styling, metadata and tests, with real before and after examples.

Download as PDF

Address: https://doc.exponential.earth/exphelp/viewer/help/extension-development/part-4-upgrading/README.md

On this page

Part 4: Upgrading an old extension to Exponential 6

This is the fourth part of Extension development: the book. It is for anyone who has an extension that was written for an older release and an older PHP: one you found on GitHub, one your team wrote ten years ago, or one you adopted. Exponential 6 keeps the extension system the old extensions were written for, so most of them need only small changes. This part shows which ones, in the order you meet them, and every example of a change is a real commit from an extension this project brought up to date (the repository and the short commit hash are named next to it, so you can read the whole change on GitHub).

How this part is organized

GroupChaptersWhat you get
Getting readyWhy most of the changes are small, The upgrade checklist, Taking inventory of an old extensionwhat to expect, the whole job on one page, and how to see what you have
PHPPHP 8 errors that stop old code, PHP 8.1 to 8.5 deprecations, Removed PHP functions, Old-style constructors and static calls, Nullable parameters, Dynamic properties, Database codeeach kind of PHP change, how to find it, how to fix it
Metadataezinfo.php and extension.xml, composer.jsonthe files that tell the system and Composer who you are
The browserInline scripts, Event handler attributes, javascript: links and eval, Inline CSS, YUI to expui, jQuery 4Content Security Policy and the JavaScript libraries of Exponential 6
The administrationadmin4 styling, Context menusmaking your pages look and work like the rest of the admin
FinishingNaming and branding, Tests and CInames, credit, and keeping it working
Case studiesexpchangeclass, the layouts editor on jQuery 4, two-factor authentication, small fixes across many extensionswhole upgrades told from start to end

The short version

If you read only one page of this part, read The upgrade checklist. If you want to start right away:

  1. Copy the extension into extension/ of a development installation (never a live site first).
  2. Run php -l on every PHP file with the oldest PHP you want to support (8.0 is the oldest Exponential 6 supports; 7.4 is usable without support).
  3. Activate it, open its pages with the debug output on, and write down every error, warning and "Deprecated" line that names one of its files.
  4. Fix those, one kind at a time, with the chapters of this part.
  5. Open the browser console on its pages and fix what the Content Security Policy blocks.
  6. Give ezinfo.php, extension.xml and composer.json the current version, license and website.
  7. Add a test that keeps it that way.

Note

You may only upgrade, publish and share an extension the way its license allows. Read Reading licenses before you reuse anything before you change an extension someone else wrote, and keep their copyright notices.

What you need before you start

You needWhyWhere it is explained
A development installation of Exponential 6you will break things on purposeTools you need
Gitto see every change you make and undo itDevelop with Git
The debug outputto see warnings and deprecationsDebug output and logs for developers
A browser with developer toolsto see what the Content Security Policy blocksContent Security Policy for extensions
Part 3 of this book, at least the anatomyyou need to know where things livePart 3

Become an Exponential Partner

Partners share their information, provide funding, contribute back and develop the products with us, and that is how Exponential grows. A partner website and dashboard are planned for mid-2027: please become a partner today to speed up our growth rate and land new features faster.

Something wrong on this page? Report an error

Documentation license

This documentation is free documentation, licensed under the GNU Free Documentation License 1.3 or later.

Exponential Copyright © 1998-2026 Exponential Foundation and 7x