This is an old revision of the document!


Technical changes in Piwigo 2.7

add_event_handler() 4th parameter

The fourth parameter of add_event_handler function was used to tell the number of parameters which will be transmitted to the callback. This is no longer used: all parameters given to trigger_change or trigger_notify are always transmitted to all callback.

But the fourth parameter is still used: if a string is given it will be used as a file path included just before the callback (with include_once).

// procedural
add_event_handler('init', 'my_init',
  EVENT_HANDLER_PRIORITY_NEUTRAL,
  MY_PLUGIN_PATH . 'include/callbacks.php'
  );
 
// OOP with static method
add_event_handler('init', array('MyClass', 'init'),
  EVENT_HANDLER_PRIORITY_NEUTRAL,
  MY_PLUGIN_PATH . 'include/myclass.php'
  );

If the 4th parameter is anything else than a string it is ignored.

trigger_change / trigger_notify

TODO

Plugin maintenance class

TODO

conf_update_param

TODO

Date(-time) inputs

TODO

Selectize

TODO

picture.tpl - disable website field

We added an option to disable or enable the website field on comment add form. You must wrap the field in a IF block:

{if $comment_add.SHOW_WEBSITE} ... {/if}
 
Back to top
dev/changes_in_2.7.1403437407.txt.gz · Last modified: 2014/06/22 11:43 by mistic100
 
 
github twitter newsletter Donate Piwigo.org © 2002-2024 · Contact