[tomcat] branch 7.0.x updated: Update reqparams.html

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

[tomcat] branch 7.0.x updated: Update reqparams.html

Mark Thomas-2
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch 7.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git

The following commit(s) were added to refs/heads/7.0.x by this push:
     new 9a16082  Update reqparams.html
9a16082 is described below

commit 9a160829ce69e7c58d854b2726112e6bb111d576
Author: javierlete <[hidden email]>
AuthorDate: Wed Jul 8 10:52:16 2020 +0200

    Update reqparams.html
    Added the request.getParameter that were missing.
    (cherry picked from commit 6c992e2b9ef09d7d7ce282630321084834f6a4ae)
 webapps/examples/servlets/reqparams.html | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/webapps/examples/servlets/reqparams.html b/webapps/examples/servlets/reqparams.html
index 7128e39..02dbddf 100644
--- a/webapps/examples/servlets/reqparams.html
+++ b/webapps/examples/servlets/reqparams.html
@@ -44,6 +44,10 @@
         out.println(&quot;<font color="#009900">&lt;body&gt;</font>&quot;);
         out.println(&quot;<font color="#009900">&lt;h3&gt;Request Parameters Example&lt;/h3&gt;</font>&quot;);
         out.println(&quot;<font color="#009900">Parameters in this request:&lt;br&gt;</font>&quot;);
+        String firstName = request.getParameter("firstname");
+        String lastName = request.getParameter("lastname");
         if (firstName != null || lastName != null) {
             out.println(&quot;<font color="#009900">First Name:</font>&quot;);
             out.println(&quot;<font color="#009900"> = </font>&quot; + HTMLFilter.filter(firstName) + &quot;<font color="#009900">&lt;br&gt;</font>&quot;);

To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]