Questions about the API

Creating and modifying plugins.
Post Reply
Posts: 6
Joined: Tue Jul 20, 2004 7:27 pm
Location: Brisbane, Australia

Questions about the API

Post by Maliuta » Fri Jul 23, 2004 1:28 am

I note in the get_config() method there is a parameter for default value. How does this work? If I want a default value of 30 do I just pass is like get_config('my_config', 30)?

I would really like to be able to code the default values in like that.

I am also interested in what types I can put in the configuration ... everyone uses "text", but I also see "select" used in one plugin.


User avatar
Core Developer
Posts: 30020
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany

Re: Questions about the API

Post by garvinhicking » Fri Jul 23, 2004 1:59 pm

Yes. Exactly like you wrote it, it works. :-)

The available types are: seperator, select, boolean, radio, string, html, hidden. Grep through the plugins to see examples for plugins using that methods. Some of them need an extra bag value 'select_values' to be set.

# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy:
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby:

Post Reply