Ticket #209 (closed defect: duplicate)
Create common function for inserting button for the plugins
|Reported by:||kim@…||Owned by:||gogo|
ref. thread : http://xinha.gogo.co.nz/punbb/viewtopic.php?pid=1379
Looking at the plugins there seems to be several ways of inserting the button, not to say placing the button. It seems that people have come up with several ways of doing this, and we should make a common function for this which all plugins should use.
My suggestion would be, that after the button is registered we should place it something like this.
[b]replaceButton/b : This would be the name of the button, and if this button alreay exist in the buttons array it will be overwritten / replaced.
[b]searchButton/b : If the replaceButton doesnt exist, we search for this button, and if we find it we insert the button (parameter1) before/after this button (parameter 3).
[b][before/after]/b : string : should we insert the button before or after the serchButton
If all fails, we insert the button in the button array, as parameter 3 would suggest.