<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <title>serveResource of MVCPortlet is not fetching formdata.</title>
  <link rel="self" href="https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=121328054" />
  <subtitle>serveResource of MVCPortlet is not fetching formdata.</subtitle>
  <id>https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=121328054</id>
  <updated>2026-04-07T05:14:15Z</updated>
  <dc:date>2026-04-07T05:14:15Z</dc:date>
  <entry>
    <title>RE: serveResource of MVCPortlet is not fetching formdata.</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121328421" />
    <author>
      <name>Mohammed Yasin</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121328421</id>
    <updated>2022-01-13T15:36:03Z</updated>
    <published>2022-01-11T20:16:01Z</published>
    <summary type="html">&lt;p&gt; Hi,&lt;/p&gt;
&lt;p&gt;You may need to prepend the parameter name with PortletNamespace
  before submitting to fetch it in ParamUtil. &lt;/p&gt;
&lt;pre&gt;
&lt;code class="language-java"&gt;//Using taglib
&amp;lt;portlet:namespace/&amp;gt;cookieConsent=false
//Using Scriptlet      
&amp;lt;%=renderResponse.getNamespace()%&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt; or &lt;/p&gt;
&lt;p&gt;directly get it from Request Object&lt;/p&gt;
&lt;pre&gt;
&lt;code class="language-java"&gt;request.getParameter(&amp;quot;cookieConsent&amp;quot;);&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt; &lt;/p&gt;</summary>
    <dc:creator>Mohammed Yasin</dc:creator>
    <dc:date>2022-01-11T20:16:01Z</dc:date>
  </entry>
  <entry>
    <title>serveResource of MVCPortlet is not fetching formdata.</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121328053" />
    <author>
      <name>Durai pandian</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121328053</id>
    <updated>2022-01-11T19:11:42Z</updated>
    <published>2022-01-11T19:05:13Z</published>
    <summary type="html">&lt;p&gt;For ajax call I am sending two parameters a form data.&lt;/p&gt;
&lt;p&gt;In the serveResource I am getting the formdata like :&lt;/p&gt;
&lt;p&gt;ParamUtil.getBoolean(request, &amp;quot;cookieConsent&amp;quot;)&lt;/p&gt;
&lt;p&gt;ParamUtil.getLong(request, &amp;quot;cookieConsentDate&amp;quot;)&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;
  &lt;strong&gt;I am receiving only null value.&lt;/strong&gt; Thanks in advance. &lt;/p&gt;
&lt;p&gt;
  &lt;img alt="" src="/documents/14/0/cookie.png/60719139-6217-f73d-ad8f-8df8ae1daabd?t=1641927750622&amp;amp;imagePreview=1" /&gt;
  &lt;br /&gt;  &lt;/p&gt;</summary>
    <dc:creator>Durai pandian</dc:creator>
    <dc:date>2022-01-11T19:05:13Z</dc:date>
  </entry>
</feed>
