
CGI::Application::Plugin::MetadataDB

use CGI::Application::Plugin::MetadataDB;
use CGI::Application::Plugin::Feedback;
use CGI::Application::Plugin::Session;
$ENV{HTML_TEMPLATE_ROOT} = '';
sub mdw_search : Runmode {
my $self = shift;
}
sub mdw_search_results : Runmode {
my $self = shift;
}
See Medatata::DB::WUI code for example usage.

Methods to aid building search to use Metadata::DB You will need to import the following plugins in your cgi app CGI::Application::Plugin::Session; CGI::Application::Plugin::Feedback;
Metadata::DB::Search makes use of a database.

the main things you want to customize are
my $default = q{
<div>
<i><TMPL_VAR LIST_INDEX></i>
id <TMPL_VAR ID>
<TMPL_VAR META_AS_UL_HTML>
</div>
};
$o->mdw_result_code($default);

These methods are meant to aid you in creating runmodes that interact with Metadata::DB
argument is id number, returns html template params in hashref
argument is a list of ids, (not array ref)
returns a loop suitable for html template, uses mdw_record_params()
perl setget method, returns result code for one object you can override this
This is a setget method, opt arg is a HTML::Template object returns HTML::Template object by default we look for ENV HTML_TEMPLATE_ROOT / mdw_search.html you can provide your own template by passing to the method before run
this is like mdw_search_results_tmpl() by default looks for mdw_search_results.html you can pass it another template to use
setget method, default is mdw_search_results.html
setget method, default is mdw_search.html

Presently we require that the search template, generated by Metadata::DB::Search::InterfaceHTML be present on disk, if you have various of these you may want to define which to use before you run() your cgiapp
$wui->mdw_search_tmpl_name('mdw_search.people.html');
And maybe change the output also for each record..
$wui->mdw_search_results_tmpl_name('mdw_search_results.people.html');
$wui->run;
Of course you can also provide template objects via mdw_search_results_tmpl() etc.