Submit buttons and param name

Discussion in 'Perl Misc' started by drood, Nov 21, 2006.

  1. drood

    drood Guest

    This allows a user to look for data on 2 different servers.

    #########################
    print submit(-name=>'choice', -value=>'Check Main Server ');
    print "<br>";
    print submit(-name=>'choice', -value=>'Check Local Server');
    ##########################

    When I check which button is selected using:

    #############################
    foreach $name ( param() ) {
    $value = param($name);
    print "$name = $value<br>";
    }
    #############################

    , I either get:

    local = Check Local Server
    or
    main = Check Main Server

    It seems the name of the param, local or main, is self generated. The
    word 'main' and 'local' do not appear in the program.

    What's the deal?
     
    drood, Nov 21, 2006
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Geathaa
    Replies:
    2
    Views:
    727
    Geathaa
    Jul 30, 2003
  2. Replies:
    4
    Views:
    1,014
  3. ectoplasm
    Replies:
    12
    Views:
    672
    Zorro
    Jul 28, 2005
  4. Dave
    Replies:
    5
    Views:
    753
    John Bokma
    Apr 26, 2011
  5. Steven Bethard
    Replies:
    14
    Views:
    217
    Thomas 'PointedEars' Lahn
    Sep 7, 2007
Loading...

Share This Page