Quick links: Content - sections - sub sections
EN

Trace: 1.0beta3

Wiki: Sitemap - Recent Changes - Back link

Jelix 1.0 beta 3

2007, 14 september (svn 583)

Main improvements

  • Full implementation of jForms, the form system of Jelix: automatic checking of the datas, server side and client side; automatic generation of a HTML form.
  • Generic controller for ??CRUD|Create Read Update Delete??, to quickly produce screens of table contents management (using a DAO and a jform).
  • support of drivers in jAcl
  • Automatic control of configuration parameter, basePath.
  • new junittests module to facilitate the creation of unit tests
  • possibility to have templates specific to languages
  • Reorganization of plugins directories: concept of plugin is not any more restricts to the plugins of the coordinator, but this concept indicates also the drivers of authentification, jDb, plugins of templates etc. It facilitates and improves teh extensibility of the framework, without modifying the jelix directory. Moreover, the naming of the functions of the plugins slightly changed.
  • Official distribution of Jelix 1.0beta3 is not compatible any more with PHP 5.0, but it is only designed for PHP versions higher than 5.1. (However you can build your own jelix distribution for PHP 5.0 starting from the sources).
  • better support of HTTP headers in the responses
  • better automatic control of the language of the navigator in the plugin autolocale

To update since jelix 1.0 beta 2/2.1

Because of some modifications in Jelix 1.0beta3, here what you must do to update Jelix and your application:

  • remove the directories lib/jelix and lib/jelix-plugins/ (recover your own files if you put some in these directories, you will reinstall them then)
  • remove the directory lib/jelix-modules/jelix
  • remove the contents of the directory temp of your application
  • install the new directory lib/jelix, lib/jelix-plugins (which is empty in the beta3) and the other directories provided.
  • modify the configuration file of your application, and other source files, by changing the names of the parameters defaultModule, defaultAction, defaultLocale, defaultCharset, defaultTimeZone, defaultTheme, respectively by the names startModule, startAction, local, charset, timeZone and topic.
  • If you created plugins of coordinator:
    1. place them in under directory coord/in your directory of plugins (example: your-appli/plugins/exemple becomes your-appli/plugins/coord/exemple
    2. rename your plugin files : exemple.plugin.php to exemple.coord.php
    3. in your plugin files, change the name of the interface jIPlugin to jICoordPlugin
  • If you created your own drivers of authentification, drivers jdb, rename also the files and the names of the classes (see documentation on the plugins)
  • if you created plugins of templates
    1. move your directories common, html etc in a sub-directory tpl/ of your directory plugins (in your-appli/plugins/tpl thus)
    2. in the configuration files of your application, remove the line tplpluginsPath which is not necessary any more
    3. modify the function names of your plugins, by following the pattern “jtpl_plugintype_outputtype_pluginname” where plugintype is the type of plugin (function, to modify etc.), outputtype is the type of format (HTML if it is in repertory HTML, common if it is in the repertory common etc.).
  • In your DAO files:
    • change the attribute names selectmotif, updatemotif and insertmotif, to selectpattern, updatepattern and insertpattern (but it is not an urgency, the old names are still recognized in the beta3)
    • in your methods in PHP, change the call to $this→_pkFields into $this→getPrimaryKeyNames ().
  • In your PHP files, if you use jDatetime, change the names of the constant BD_* into DB_* (but it is not an urgency, the old names are still recognized in the beta3)
  • if you use JSON class (lib/JSON/) directly, replace the call by the use of the new class jJson.
  • There were many modifications in the format of the jForms files. Refer to the documentation to know the new XML grammar.
  • Change the call to the classes jAclManager and jAclUserGroup by jAclDbManager and jAclDbUserGroup (see the details of the changes)
  • Use of the requests jsonrpc and xmlrpc: received parameters RPC are now in a single parameter jelix “params”.

Details of the changes

API changes

  • jDao: the attributes selectmotif, updatemotif and insertmotif were renamed to selectpattern, updatepattern, insertpattern. The old names are valid until the version 1.0.
  • jException: the method getMessage return the localized message instead of the key of the message. There are no more the properties localizedMessage, localeParams, and the method getLocaleMessage. New methods: getLocaleKey and getLocaleParameters.
  • Reorganization of directories of the plugins coordinator, drivers of authentification, drivers for jDb and of the engines of urls. For the details, see the page of the plugins
    • Now the directories indicated by the parameter pluginsPath of the configuration contains all these plugins, classified in distinct sub-directories.
    • The naming of classes and plugins files for the coordinator was modified, following the reorganization of the directories of plugins. The names of the files become foo.coord.php, the names of the classes fooCoordPlugin. And the plugins are moved under directories coord/directories jelix-plugins etc. The interface jIPlugin was renamed to jIAuthPlugin.
    • The naming of classes and files, for authentification drivers, jDb, the engines of urls and the plugins of templates also changed.
  • jDateTime: the constant BD_* were renamed to DB_*. The old names are nevertheless valid to version 1.0.
  • Modifications in the format of the files jForms.
  • Modifications in the files of configurations: the names of the parameters defaultModule, defaultAction, defaultLocale, defaultCharset, defaultTimeZone, defaultTheme, were renamed respectively to startModule, startAction, local, charset, timeZone and topic.
  • jAcl:
    • jAclManager becomes jAclDbManager
    • jAclUserGroup becomes jAclDbUserGroup
    • jAcl:: isMemberOfGroup () moved in jAclDbUserGroup
    • jAcl:: getDbProfil () moved in jAclDb (new class) and renamed to getProfil ()

Improvements, new features

  • Configuration:
    • The parameter of configuration basePath is now detected automatically when its value is empty. However, for the applications which have several entry points in different directories, it should set up.
    • New parameter jelixWWWPath, which indicates the URL path to the contents of the jelix-www directory.
  • Improvement of the automatic control of language in the plugin autolocale
  • jForms: complete implementation, which thus includes:
    • method check () (which validate data in a form), was largely improved and debugged
    • new template plugins to generate a form HTML corresponding to an object form jForms. It includes also the automatic generation of the validation Javascript, the posting of the errors detected etc.
    • new methods saveFile and saveAllFile, which makes it possible to easily save the uploaded files of a form.
  • jResponse:
    • new method clearHttpHeaders ()
    • a 500 http code is sent when there are errors
    • jResponseHtml: adding the support of the alternate style sheets
    • jResponseJson and jResponseJsonRpc: HTTP code of the answer can be set up. (ticket 157)
  • jTpl:
    • you can have templates, specific to a language, by putting them in sub-directories having for name the code of a language (like in the locales directory)
    • you can force the type of template (HTML, text etc.) when you call the fetch method (and other methods of jtpl). It is useful when you want to use a template to generate the contents of an email for example, independently of the type of the response of the action.
    • New types of plugins of templates, cfunction and cmodifier: they are plugins called during the compilation of the template rather than to posting, which makes it possible to improve the performances.
    • new modifier “count” to get the number of element of a table
    • you can indicate if a template is secured or not (3rd parameter with the methods display, fetch…)
    • new modifier eschtml (identical to escxml)
    • the arguments of the modifiers can now be separated by commas (ticket #129)
    • Addition of default variables in templates: j_datenow, j_timenow, j_basepath, j_jelixwww
  • jDateTime: (ticket #176)
    • new method now ()
    • modification on the methods add () and sub (): they still accept a jDateTime object in parameter, but there is now a new alternative. They can now accept the parameters year, month, day, hour, minute, second,.
    • the constant BD_* were renamed to DB_* but old name are still usable (deprecated)
  • jDao:
    • new methods jDaoRecordBase:: getPk (), jDaoRecordBase:: getPrimaryKeyNames (), jDaoFactoryBase:: deleteBy (), jDaoFactoryBase:: getPrimaryKeyNames (), jDaoFactoryBase:: getProperties ().
    • new type of property: text
  • jAuth:
    • support of persistent authentification (ticket #229)
    • the name of the session variable (which contains information about a connected user) is now configurable, and thus makes it possible to use several type of authentification in the same application
    • new method jAuth:: getRandomPassword ()
    • possibility to indicate a name of profile for db driver
  • jAcl is based now on a system of driver, allowing the choice of the data source for the rights. The old implementation of jAcl was thus moved towards a driver “dB”. The drivers must implement the new interface jIAclDriver.
  • jUrl:
    • for the significant engine: several significant urls can now point to the same action if they have static parameters which differentiate them
  • New class jJson and jCrypt.
  • New controller, jControllerDaoCrud, to make a data management on a table, with lists, edition, deletion of records. It uses a dao and a form you should provided.
  • New module junittests to be able to easily make unit tests in the modules.
  • Improvements on the script of checking of installation
  • Addition of a script to create a whole CRUD interface starting from one only table
  • Activation of the detection of typical mistakes E_STRICT
  • Improvement of the API documentation in jAuth, jDao, jUrls, plugins of templates

Bug fixes

  • jDb, driver pdo: the PDO driver returned a table instead of an object during the use of the resultSet as a iterator (because of a bug in PDO). (ticket #180)
  • jDao:
    • an empty “value” attribute was not authorized (ticket #191)
    • bad formatting for the method.limit.forbidden error
    • removal of a notice in jDaoRecordBase:: setPk ()
    • bad generation of the conditions with the use of operators IN/NOT IN (bug #203).
    • the names of the tables and the fields in the queries are now generated between quotes, in order to be able to correctly use these names in Postgresql and mysql. (bug #98)
    • for the optional properties, the methods did not check if the corresponding dynamic values were null, and if thus a IS NULL had to be generated or not during their use in clauses WHERE. (ticket #228)
    • fixed bugs on the “autoincrement” properties
  • jTpl:
    • (regression) the use of the keywords “true”, “false” and “null” was not possible any more because php sees them like constants
    • some operators were usable in some template tags. It is not usable any more.
    • the same compiled file of template was used during the use of the template in answers of the different type (bug #225)
    • it was possible to include PHP tags in a template, which is a potential security hole for the templates which are not trusted (uploaded by a user for example).
    • It was not possible to put jtpl tags in comment (bug #106)
  • jResponses:
    • HTTP headers were not well managed in some response objects : we could not modify them (ticket #198).
    • jResponseBinary: the property mimeType was not declared (ticket #188)
    • jResponseXmlRpc and jXmlRpc: bug during the analysis of the data of the type struct (ticket #190 et#192) and of the name of the method (ticket #245 and #243).
    • rss and atom: the language code was badly generated (ticket #247)
  • jUrl, engine of significant URL: in the file xml, parameter of the type dates, the days “10” and “20” were not recognized (ticket #204)
  • jAuth: bad operator in jauth.listener.php (bug #221).
  • jControllerCmdLine: the signature of the method param () was not identical to that of its mother class
  • Problem of encoding with class JSON included in Jelix: update of this class (bug #321)
  • Problem of encoding at the time of the sending of the emails

en/changelog/1.0beta3.txt · Last modified: 2007/10/19 12:15 by 127.0.0.1
Recent changes RSS feed Creative Commons License