Branch: Tag:

2002-02-26

2002-02-26 13:17:18 by Marcus Wellhardh <wellhard@roxen.com>

Added support for autosubmit to Variable.MiltipleChoice

Rev: server/etc/modules/Variable.pmod/module.pmod:1.75

1: - // $Id: module.pmod,v 1.74 2002/01/29 15:30:43 mast Exp $ + // $Id: module.pmod,v 1.75 2002/02/26 13:17:18 wellhard Exp $      #include <module.h>   #include <roxen.h>
1058:       string render_form( RequestID id, void|mapping additional_args )    { -  string res = "<select name='"+path()+"'>\n"; +  string autosubmit = ""; +  if(additional_args && additional_args->autosubmit) +  autosubmit = " autosubmit='autosubmit' onChange='javascript:submit();'"; +  string res = "<select name='"+path()+"'"+autosubmit+">\n";    string current = _name (query());    int selected = 0;    foreach( get_choice_list(), mixed elem )