diff options
author | mrjive <mrjive@mrjive.it> | 2015-11-11 16:51:48 +0100 |
---|---|---|
committer | mrjive <mrjive@mrjive.it> | 2015-11-11 16:51:48 +0100 |
commit | 53a796afcc0cff6f9e3f51457df4506a43db1945 (patch) | |
tree | a2366c48e0dae047b052283cc44284224369c8cd /doc/hook/validate_channelname.bb | |
parent | a4c3058f845a1c38d06b2201a10700c5f878366d (diff) | |
parent | bc7c0ed844711e81c4bc642e3024849195a48421 (diff) | |
download | volse-hubzilla-53a796afcc0cff6f9e3f51457df4506a43db1945.tar.gz volse-hubzilla-53a796afcc0cff6f9e3f51457df4506a43db1945.tar.bz2 volse-hubzilla-53a796afcc0cff6f9e3f51457df4506a43db1945.zip |
Merge pull request #8 from redmatrix/master
get fresh code from HZ base
Diffstat (limited to 'doc/hook/validate_channelname.bb')
-rw-r--r-- | doc/hook/validate_channelname.bb | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/doc/hook/validate_channelname.bb b/doc/hook/validate_channelname.bb new file mode 100644 index 000000000..2ab12bbec --- /dev/null +++ b/doc/hook/validate_channelname.bb @@ -0,0 +1,23 @@ +[h2]validate_channelname[/h2] + +Called when creating a new channel or changing the channel name in mod/settings.php + +Hook data consists of an array + + array( + 'name' => supplied name + ); + + If the hook handler determines the name is valid, do nothing. If there is an issue with the name, + set $hook_data['message'] to the message text which should be displayed to the member - and the name will + not be accepted. + + + Example: + [code] + if(mb_strlen($hook_data['name']) < 3) + $hook_data['message'] = t('Name too short.'); + [/code] + + +
\ No newline at end of file |