Results 1 to 5 of 5

Thread: Get form input values via their ID tag in Perl

Threaded View

  1. #1

    Thread Starter
    Frenzied Member Rick Bull's Avatar
    Join Date
    Apr 2002
    Location
    England
    Posts
    1,444

    Get form input values via their ID tag in Perl

    I'm new to perl and I wrote a basic form parser library that extracts any form name/value pairs and returns them via a hash (attached, renamed from .lib to .txt). This works fine for form inputs with the NAME attribute, but using XHTML I want to replace NAME with ID. Is there anyway I can do it?


    Here is the Perl file that extracts the arguments:

    Code:
    #/usr/bin/perl
    use strict;
    use CGI::Carp qw(fatalsToBrowser);
    require "form_data.lib";
    
    my %data = &parseForm;
    my $loopItem;
    print "content-type:text/plain\n\n";
    foreach $loopItem (keys %data) {
      print "$loopItem = $data{$loopItem}\n";
    }
    Last edited by Rick Bull; Jul 2nd, 2002 at 10:22 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width