Return-Path: X-Original-To: apmail-perl-embperl-archive@www.apache.org Delivered-To: apmail-perl-embperl-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 5E4AA18247 for ; Mon, 24 Aug 2015 17:42:15 +0000 (UTC) Received: (qmail 86933 invoked by uid 500); 24 Aug 2015 17:42:15 -0000 Delivered-To: apmail-perl-embperl-archive@perl.apache.org Received: (qmail 86908 invoked by uid 500); 24 Aug 2015 17:42:15 -0000 Mailing-List: contact embperl-help@perl.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list embperl@perl.apache.org Received: (qmail 86895 invoked by uid 99); 24 Aug 2015 17:42:15 -0000 Received: from Unknown (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 24 Aug 2015 17:42:14 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id 9786E1826D6 for ; Mon, 24 Aug 2015 17:42:14 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -0.006 X-Spam-Level: X-Spam-Status: No, score=-0.006 tagged_above=-999 required=6.31 tests=[RP_MATCHES_RCVD=-0.006] autolearn=disabled Received: from mx1-us-west.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id jR4xzVkmmzID for ; Mon, 24 Aug 2015 17:42:07 +0000 (UTC) Received: from facteur.thefreecat.org (facteur.thefreecat.org [212.129.38.6]) by mx1-us-west.apache.org (ASF Mail Server at mx1-us-west.apache.org) with ESMTPS id 5DD13254F5 for ; Mon, 24 Aug 2015 17:42:07 +0000 (UTC) Received: from [192.168.0.17] (41-22-190-109.dsl.ovh.fr [::ffff:109.190.22.41]) (AUTH: PLAIN cat, SSL: TLSv1/SSLv3,128bits,AES128-SHA) by facteur.thefreecat.org with ESMTPSA; Mon, 24 Aug 2015 19:01:59 +0200 id 000000000270000F.0000000055DB4E0B.000036CD Message-ID: <55DB4E07.2020406@thefreecat.org> Date: Mon, 24 Aug 2015 19:01:59 +0200 From: Jean-Christophe Boggio User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.8.0 MIME-Version: 1.0 To: "embperl@perl.apache.org" Subject: Question concerning REST Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Hello, I am trying to implement a simple REST/JSON server in embedded perl but I don't understand how I can retrieve the data sent to me. I test with this command : curl -i -X GET -d '{"name":"john"}' http://omico.miaou/rest/notifent.html And the following code shows nothing (apart from the %ENV stuff) : [- use Data::Dumper; $req = shift; while ( ($k,$v) = each(%fdat) ) { warn "$0:FDAT $k : ".Dumper($v); } while ( ($k,$v) = each(%udat) ) { warn "$0:UDAT: $k : ".Dumper($v); } while ( ($k,$v) = each(%ENV) ) { warn "$0:ENV: $k : ".Dumper($v); } foreach $k (@param) { warn "$0:param: $k "; } -] Thanks for your help, JC --------------------------------------------------------------------- To unsubscribe, e-mail: embperl-unsubscribe@perl.apache.org For additional commands, e-mail: embperl-help@perl.apache.org