Foros de discusión

Getting parameters from .js file to action class

thumbnail
Bharamani P Tashildar, modificado hace 9 años.

Getting parameters from .js file to action class

Junior Member Mensajes: 48 Fecha de incorporación: 27/08/14 Mensajes recientes
friends

How to get parmeters from .js file to action class .

in my .js file
$(document).on("click", "#dialog #borderbottom" , function() {
var _this = $("#dialog .container-fluid .episode");
var url = $(_this).find("#url").text();
var duration = $(_this).find("#duration").text();
var title = $(_this).find(".text-center").text();
var poster = $(_this).find("img").attr("src");
var resourceURL = Liferay.PortletURL.createResourceURL();
resourceURL .setParameter("url",url);
resourceURL .setParameter("duration",duration);
resourceURL .setParameter("title",title);
resourceURL .setParameter("poster",poster);
return resourceURL.toString();
});


i want to get all parameters in my .java class

please tell me solution..
thumbnail
srikanth velugoti, modificado hace 9 años.

RE: Getting parameters from .js file to action class

Junior Member Mensajes: 79 Fecha de incorporación: 24/04/09 Mensajes recientes
Hey Bharamani ,

check this link

HTH ,
srikanth
thumbnail
Víctor Ponz, modificado hace 9 años.

RE: Getting parameters from .js file to action class

New Member Mensajes: 18 Fecha de incorporación: 29/07/14 Mensajes recientes
From HttpServletRequest you can access an url parameter

		import com.liferay.portal.kernel.util.ParamUtil;
		.....
		String yourParameter = ParamUtil.getString(request, "your-parameter");


Hope it helps