// wait until the DOM is ready
function domReady ()
{
- document.mkwsSearchForm.onsubmit = onFormSubmitEventHandler;
+ $('.mkwsSearchForm').each(function (i, obj) {
+ var node = this;
+ debug("adding class 'foo' to node " + node);
+ mkws.handle_node_with_team(node, function(tname) {
+ $(node).submit(onFormSubmitEventHandler);
+ });
+ });
+
document.mkwsSearchForm.mkwsQuery.value = '';
if (document.mkwsSelect) {
if (document.mkwsSelect.mkwsSort)
// Find all nodes with class (NOT id) mkwsRecords, and
// determine their team from the mkwsTeam_* class. So:
// <div class="mkwsRecords mkwsTeam_foo"/>
- $('.mkwsResults, .mkwsRecords, .mkwsTermlists').each(function () {
+ $('.mkwsSearch, .mkwsResults, .mkwsRecords, .mkwsTermlists').each(function () {
var node = this;
mkws.handle_node_with_team(node, function(tname) {
if (mkws.teams[tname]) {