MiniVend Akopia Services

[Date Prev][Date Next][Thread Prev][Thread Next][Minivend by date ][Minivend by thread ]

Changing multiple value delimeter



******    message to minivend-users from allan@instantsoft.com     ******


sub parse_post {
        my(@pairs, $pair, $key, $value);
        undef %CGI::values;
        return unless defined $CGI::post_input;
        @pairs = split(/&/, $CGI::post_input);
        foreach $pair (@pairs) {
                ($key, $value) = ($pair =~ m/([^=]+)=(.*)/)
                        or die "Syntax error in post input:\n$pair\n";
                $key = unhexify($key);
                $value =~ s/\+/ /g;
                $value = unhexify($value);
                # Handle multiple keys
                unless (defined $CGI::values{$key}) {
                        $CGI::values{$key} = $value;
                }
                else {


#############################
## QUESTION HERE
## QUESTION HERE
#############################
## If I change "\0" below to something else like
## say '|'   , will minivend break? If yes, does anyone
## know how to get all the values from a select multiple
## using [value varname]? The way it is right now, if you
## do something like:
## <select name=vname multiple size=4>
##	<option value=1>1
##	<option value=2>2
##	<option value=3>3
## </select>
## [value vname] returns only one value.
##

                        $CGI::values{$key} .= "\0" . $value;
                }
        }
        if($Global::TolerateGet and !$CGI::query_string  ) {
                $CGI::query_string =    $CGI::values{mv_session_id} || '';
                $CGI::query_string .=   ';';
                $CGI::query_string .=   $CGI::values{mv_argument}   || '';
                $CGI::query_string .=   ';0';
        }
}


-
To unsubscribe from the list, DO NOT REPLY to this message.  Instead, send
email with 'UNSUBSCRIBE minivend-users' in the body to Majordomo@minivend.com.
Archive of past messages: http://www.minivend.com/minivend/minivend-list


Search for: Match: Format: Sort by: