Passing json data from one jsp to another in Liferay -


i new liferay , ended failing send data 1 jsp other. below use case.

  1. i have created 2 jsp files: first.jsp , second.jsp
  2. i have created href in first.jsp , on clicking of that, loading second.jsp calling renderurl.
  3. all want achieve constructing json data in first.jsp , when click href tag, need pass json data second.jsp file.

any pointers on how achieve task appreciated?

thanks.

i able send data creating renderurl in javascript code show below. posting might me out there :)

in first.jsp:-

<script> aui().ready('liferay-portlet-url', function(a) {                  var renderurl = liferay.portleturl.createrenderurl();                  renderurl.setparameter("jsppage","/html/testsample/testsamplepage.jsp");                  renderurl.setportletid("testsamplepage_war_testsamplepageportlet");                  renderurl.setparameter("rowdata",data);                  window.location.href = renderurl; </script> 

then in second.jsp:-

<% system.out.println(request.getparameter("rowdata")); %> 

Comments

Popular posts from this blog

Android layout hidden on keyboard show -

google app engine - 403 Forbidden POST - Flask WTForms -

c - Why would PK11_GenerateRandom() return an error -8023? -