thom has asked for the wisdom of the Perl Monks concerning the following question:

Dear monks

I'd like to write a module for Webmin and I found this How to on the project's website.

Does anybody know another tutorial on writing Webmin modules?

Thanks in advance, Thom

Replies are listed 'Best First'.
(jeffa) Re: Writing Webmin Modules
by jeffa (Bishop) on May 01, 2003 at 14:35 UTC
    I sure don't. Since that tutorial is actually on the Webmin site and discusses it's 'API calls', i would say it is a necessary read -- but take the code given with a grain of salt. It's really bad stuff:
    do '../web-lib.pl';
    and
    require './foobar-lib.pl'; &header($text{'list_title'}, ""); print "<hr>\n"; print "<table border>\n"; print "<tr $tb>\n"; print "<td><b>$text{'list_user'}</b></td>\n"; print "<td><b>$text{'list_real'}</b></td>\n"; print "</tr>\n";
    send out all kinds of red flags. Someone should update that tutorial with more aesthetic and up-to-date Perl code.

    jeffa

    L-LL-L--L-LL-L--L-LL-L--
    -R--R-RR-R--R-RR-R--R-RR
    B--B--B--B--B--B--B--B--
    H---H---H---H---H---H---
    (the triplet paradiddle with high-hat)
    

      This is exactly what I thought after reading it.

      What is even more frightening is, that most Webmin modules are written in this style...

      thom