I got a plugin which acts differently according to a certain paramether, till now I made this through a final variable:
public class MyPlugin implements Plugin{
public static final int par = 1; //example
public void initPlugin(){
//do something according to par value
}
}
Now, if I want to change plugin’s behaviour I have to edit the sources and re-compile the plugin. Is there a way to give plugin the paramether, maybe through admin console?How?
I think I understood mechanism: you set and get a JiveGlobals property, so my function could be something like this:
public void initPlugin(){
JiveGlobals.getProperty(“myProperty”,"");
//do something according to property
}
right?
But now I have another problem: how to set the property?It would be nice to make this throught admin console, in my plugin’s tab, but I don’t know how to create tabs, buttons or anything…do you have any guide?