Migrating to v12

PHP Report Maker 12 is a major upgrade from v11, it introduces some new features which are not fully compatible with old versions. When you open an old project in v12, PHP Report Maker will try to convert the changes for you. However, the conversion cannot be 100% and you'll need to do some updates yourself. Please read the follows carefully, review your code, update and test it before deploying the new scripts to your production server.

 

PHP

Require PHP 5.5 or higher. If you use PhpSpreadsheet extension (see below), PHP 5.6 or higher is required.

Use Composer to manage required third party packages. Make sure that you enable PHP CLI and install Composer (see Generate Settings). To use Composer, please make sure that you are online during the generation process. After the first generation, Composer will download all the required packages, it may take a long time, please be patient. Later generation will not run "composer update" again unless you enable/disable some features that require third party packages. Note that the packages downloaded by Composer are put under the "vendor" subfolder.

PHP namespaces are used. The generated application is now under the default PHP namespace PHPReportMaker12\<project>. If your server events need to create instance of third party classes in other namespace, you need to update your code and add namespaces to your class names.

Since namespace is used, the EWR_ and ewr_ prefixes are removed, e.g. EWR_PROJECT_NAME becomes PROJECT_NAME and ewr_ExecuteScalar() becomes ExecuteScalar(). Also, the cr prefix for class names are also removed, e.g. crListActions becomes ListActions.

Method names are changed to camel case, e.g. $menu->addMenuItem(). Global functions still use pascal case, e.g. CurrentUserName(). (Note that PHP functions names are case-insensitive, read User-defined functions.)

No more Page_* methods (EXCEPT for server events) e.g. $this->Page_Terminate() becomes $this->terminate().

Table and page classes are now generated separately under the "classes" subfolder and they are auto-loaded. You can create instances of all these classes in your server events or custom files easily without including them.

Some new global functions (e.g. Get(), Post(), Param()) are introduced, see Some Global Functions.

Always use PHP mysqli extension for MySQL, the old mysql extension is no longer supported.

Always use Microsoft PHP Driver for SQL Server for SQL Server, connection by COM functions is no longer supported.

 

JavaScript

PHP Report Maker JavaScript is now under the ew namespace. The EWR_ and ewr_ prefixes are therefore changed to ew., e.g. EWR_LANGUAGE_ID becomes ew.LANGUAGE_ID.

Method name are changed to the more common camel case, e.g. ewr_SetSessionTimer() becomes ew.setSessionTimer(). If your client side code calls any PHP Report Maker functions, you must update them.

 

Bootstrap 4 and AdminLTE 3

Bootstrap 4 uses rem (not px) as primary CSS unit, update your font size. Many Sass variable names are also changed, update your theme settings.

AdminLTE 3 now uses Sass also (previously LESS was used), update your theme settings.

Make sure you re-generate all .css files, you can NOT re-use old .css files from previous versions. If you use your own external stylesheet, you MUST update it first.

AdminLTE 3 does not support Layout Options (e.g. Top Navigation which was used as horizontal menu in previous version) any more. There is only one layout now.

Not compatible with PHP Report Maker 2018 or earlier (see below).

 

Icons

There is no more icons in Bootstrap 4. Now Font Awesome v4 (not v5) included in AdminLTE 3 is used. Update your icon class names in Menu Editor and server events, if used.

 

HTML Element IDs and CSS Class Names

The HTML element IDs and CSS class names are changed to the more common param case (i.e. lower case, dash separated), e.g. ewTable becomes ew-table. If you specify them in your custom CSS styles and JavaScript, update them accordingly.

 

Lookup Cache

This version supports caching the lookup table (if reasonably small) and it is enabled by default. The caching is done on server side so the page may be loaded slightly slower if you have many lookup fields in the table. You may however disable and fine tune this feature by the two new advanced settings, Use lookup cache and Lookup cache count (see Advanced Settings).

 

Extensions

There is no more Top Navigation option in AdminLTE 3, the horizontal Menu extension (for registered users) is retired. However, there is a new option Navbar Item for menu items which allow you to put some (or all) menu items at the top navbar, see Menu Editor. You can show all menu items in the navbar on the top of the page, just right click the header of the Navbar Item column in Menu Editor and click Select All. In such case, the vertical menu will be hidden automatically. For mobile mode, the vertical menu is always used as mobile menu.

PHPExcel extension is replaced by the new PhpSpreadsheet extension. PhpSpreadsheet is next version of PHPExcel, note that it requires PHP 5.6 or higher.

 

Grid Component (FusionCharts)

Grid Components is no longer supported.

 

Language File

There are always new phrases in new major version, make sure you update your non-English language files or some phrases will be missing in Multi-Language projects.

 

Compatibility with PHPMaker 2019.0.5 or later only

Note that PHP Report Maker 12 uses Bootstrap 4 and AdminLTE 3 and is compatible with PHPMaker 2019.0.5 or later only.

 

 

 

 

 

 ©2007-2018 e.World Technology Ltd. All rights reserved.