Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id D4915200CFA for ; Tue, 5 Sep 2017 19:11:30 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id D3229160BCB; Tue, 5 Sep 2017 17:11:30 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id CFFC8160BD7 for ; Tue, 5 Sep 2017 19:11:29 +0200 (CEST) Received: (qmail 39218 invoked by uid 500); 5 Sep 2017 17:11:27 -0000 Mailing-List: contact users-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: users@httpd.apache.org list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list users@httpd.apache.org Received: (qmail 39202 invoked by uid 99); 5 Sep 2017 17:11:27 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 05 Sep 2017 17:11:27 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id 5A64D1A302E for ; Tue, 5 Sep 2017 17:11:27 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -0.399 X-Spam-Level: X-Spam-Status: No, score=-0.399 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=2, HTML_OBFUSCATE_05_10=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-2.8, RCVD_IN_SORBS_SPAM=0.5, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=disabled Authentication-Results: spamd2-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id SF3OMWgOfpnX for ; Tue, 5 Sep 2017 17:11:22 +0000 (UTC) Received: from mail-oi0-f47.google.com (mail-oi0-f47.google.com [209.85.218.47]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id CBF695FBB1 for ; Tue, 5 Sep 2017 17:11:21 +0000 (UTC) Received: by mail-oi0-f47.google.com with SMTP id n18so28438639oig.2 for ; Tue, 05 Sep 2017 10:11:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=qgqj/W+ZU+FKsU+WLAaIsqYjDNBQA+tojQncUiAq/7U=; b=RzxENKl0smYqIBGUfE9UUv1X2HDCKTXTzYAONld1cQmLPOXZdhf3p3LjPQs7lXqmrE 5LuTEZYQLwk4NpJl7S1wFN34N0+oOvGAiVBhzOYuytdWeYIcHfzgvm8jAibA8ebAAVZm GWQRtAC9x9hTqJQbmGWhUhOUMbH67ZLZOQ6R63PpBeHvX7m8IO5Ee62xV+lnfdUbjJHO 3s81U4+eF4NMZBf3yrKE+qTnNjtEQY0ezO2Oz/KKLedW3XT/Hb0uFB375NmIwspblEhr GGAHWQmXtGdPqpiSiN6Ua0k8nI6mQgAuvgijlNtB2P4MDPxIBDwK0Sl5pt6/70AEAyZZ 8VQg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=qgqj/W+ZU+FKsU+WLAaIsqYjDNBQA+tojQncUiAq/7U=; b=HVazxS5GvKmLajtxKUuMe6WmIH8+zANPz+r5aqtXEjxivjdwHGhu1fqUMijurCcSNf SuZXei8xR3DYbzdEYTuUVbWJNU45kxUEWBmkaoWvFl4J4r1L3Avc3v8qd0oZSUpxh8PG mSgViZvfrbvMGWR7zjMfwZ4ukvRiuFWF7XaUgAuQaE8z3z+YfuQL3Xyi5b0SQ9VY7Cm9 KTxqxwS3bOtXdKLPbqb3bjSvr+j0YRkzC/NC1usmaFSYOKCc7rpEhF0KxwyJCQ0VD9jd CQOeufx7v9g5ZzqI7po+hMdXr4aUAv3QabELIjd8HnCC9wOEqChwPaqhItH5sJu4Cj65 vivQ== X-Gm-Message-State: AHPjjUghzXu2PnRfPzzsEQe6pj9/degU/n+mzFbqdGvPiiDHijMvfixd 9TY/G4uL4DJIxe8SLp3qkCBBzNwtXkd0 X-Google-Smtp-Source: ADKCNb4HWucV7ARkT2H1PZQTTO/+hkHnUwaELmCKgpeTEht8taSMiIYi1ExxDE47SNbFxgfBFMQnKsWHYliypnFPBVo= X-Received: by 10.202.80.203 with SMTP id e194mr937566oib.3.1504631480085; Tue, 05 Sep 2017 10:11:20 -0700 (PDT) MIME-Version: 1.0 Received: by 10.168.167.133 with HTTP; Tue, 5 Sep 2017 10:11:19 -0700 (PDT) From: Srinivas Reddy Date: Tue, 5 Sep 2017 13:11:19 -0400 Message-ID: To: users@httpd.apache.org Content-Type: multipart/alternative; boundary="001a113b00d8e372ff0558745038" Subject: [users@httpd] How to pass query string as encoded value to another parameter? archived-at: Tue, 05 Sep 2017 17:11:31 -0000 --001a113b00d8e372ff0558745038 Content-Type: text/plain; charset="UTF-8" down votefavorite In my use case, I need to encode {QUERY_STRING} value and pass this value as a separate parameter. Here it is how it should work: http://www.example.com?param1=value1¶m2=value2¶m3=value3 The URL can have n number of parameters and values may contain special characters and value is an alphanumeric string. I need to transform the URL to: http://www.example.com?param1=value1¶m2=value2¶m3=value3& *originalQP=param1=value1%26param2=value2%26param3=value3* I added parameter called originalQP and it should be always encoded. How can I get this encoded string using mod rewrite flags? I tried using B and NE flags but neither of them worked. I am not getting '&' being encoded in the transformed URL instead originalQP value is being passed as param1=value1. How can I get complete value? --001a113b00d8e372ff0558745038 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable

<= p style=3D"margin:0px 0px 1em;padding:0px;border:0px;font-style:inherit;fon= t-variant:inherit;font-weight:inherit;font-stretch:inherit;font-size:inheri= t;line-height:inherit;font-family:inherit;vertical-align:baseline;clear:bot= h">In my use case, I need to encode=C2=A0{QUERY_STRING}=C2=A0value an= d pass this value as a separate parameter. Here it is how it should work:

http://www.exampl= e.com?param1=3Dvalue1&param2=3Dvalue2&param3=3Dvalue3

The URL can have n number of parameters and values may contain s= pecial characters and value is an alphanumeric string.

I need to tra= nsform the URL to:

http://www.example.com?param1=3Dvalue1&param2=3Dvalue2&para= m3=3Dvalue3&originalQP= =3Dparam1=3Dvalue1%26param2=3Dvalue2%26param3=3Dvalue3

I added parameter called=C2=A0originalQP=C2=A0and it should = be always encoded.

How can I get this encoded string using mod rewri= te flags?

I tried using=C2=A0B=C2=A0and=C2=A0NE=C2=A0fla= gs but neither of them worked. I am not getting '&' being encod= ed in the transformed URL instead=C2=A0originalQP=C2=A0value is being= passed as=C2=A0param1=3Dvalue1.

How can I get complete value?=

--001a113b00d8e372ff0558745038--