On Thu, 2003-06-05 at 20:14, David Kaufman wrote:
> Lance A. Brown <[EMAIL PROTECTED]> wrote...
> >
> > OK.  I don't think I'm doing anything too crazy with these modules,
> > but I keep running into problems with this error:
> >
> > [Thu Jun  5 17:59:49 2003] [error] [Thu Jun  5 17:59:49 2003] null:
> > Error executing run mode 'main': HTML::Template : Attempt to set
> > nonexistent parameter '</div>' - this parameter name doesn't match any
> > declarations in the template file : (die_on_bad_params => 1) at
> > SwitchManager.pm line 84
> >
> >
> > Now, I don't have a '</div>' parameter anywhere in my code.
> > HTML::Template 2.6
> 
> i've run into that error lots of times too.  but in every case it turned out
> to be because i was passing some oddly contrived data structure to the
> $template's param() function that wasn't doing what i thought it would do.

Heh.  Weird.  definitely.

> maybe.  can you post a bit of the relevent code from the general vicinity of
> line 84?

Here you go:

    # Get switch IP addresses (Array Reference)
    my $switches = get_exclude_ports_switches($dbh);

    # Get text of hidden variables controlling where to go next
    my $rm_add = $q->hidden(-name=>'rm', -default=>'add_switch');
    my $rm_ep = $q->hidden(-name=>'rm', -default=>'exclude_ports');
    my $rm_cp = $q->hidden(-name=>'rm', -default=>'config_ports');
    my $submit = $q->submit(-name=>'Go');

    # Switch IP entry field
    my $af = $q->textfield(-name=>'switch_ip',
                           -override=>1,
                           -size=>15,
                           -maxlength=>15);

    # Popup list of switch IP addresses
    my $ss = $q->popup_menu(-name=>'switch_ip',
                            -values=>$switches,
                            -default=>$$switches[0]);

    # Load template
    $main_tmpl->param(startform => $q->start_form(),
                      endform => $q->end_form(),
                      run_mode_add => $rm_add,
                      run_mode_ep => $rm_ep,
                      run_mode_cp => $rm_cp,
                      submit => $submit,
                      addfield => $af,
                      switch_select => $ss);

The call to $main_tmpl->param(...) is line 84.

I'm attaching the template file.  Could I be running into some caching
issue with mod_perl?

--[Lance]

-- 
  Carolina Spirit Quest:  http://www.carolinaspiritquest.org/
  Celebrate The Circle: http://www.angelfire.com/nc/celebratethecircle/
  My LiveJournal: http://www.livejournal.com/users/labrown/
  <table border="0" cellpadding="5" cellspacing="5" align="center">
    <tr>
      <td>
        <tmpl_var startform>
        <tmpl_var run_mode_add>
        Add a Switch to Pelican: <tmpl_var addfield>
        <tmpl_var submit>
        <tmpl_var endform>
      </td>
    </tr>
    <tr>
      <td>
        <tmpl_var startform>
        <tmpl_var run_mode_ep>
        Manage Excluded Ports for <tmpl_var switch_select>
        <tmpl_var submit>
        <tmpl_var endform>
      </td>
    </tr>
    <tr>
      <td>
        <tmpl_var startform>
        <tmpl_var run_mode_cp>
        Configure Switch Ports on <tmpl_var switch_select>
        <tmpl_var submit>
        <tmpl_var endform>
      </td>
    </tr>
  </table>

---------------------------------------------------------------------
Web Archive:  http://www.mail-archive.com/[EMAIL PROTECTED]/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to