Forums

Home » Liferay Portal » English » 3. Development

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
Sachin Aware
is it necessary to use aui tag library
February 5, 2014 8:43 AM
Answer

Sachin Aware

Rank: New Member

Posts: 23

Join Date: July 19, 2012

Recent Posts

Hi,

I am creating portlet with a form with submit action in liferay 6.2. I have text fields in it.
But I am using following line for text fields .
<input name="test" id="test" type="text" value=""/>
I am geeting null value in process action

but for following

<aui:input label="test" name="test" type="text" value="" />

gives me proper value.

Is it necessary to use aui tag library in form?

Thanks in advance.
Sampsa Sohlman
RE: is it necessary to use aui tag library
February 5, 2014 10:51 AM
Answer

Sampsa Sohlman

LIFERAY STAFF

Rank: Regular Member

Posts: 226

Join Date: September 27, 2007

Recent Posts

Hi Sachin,

Liferay is JSR-168 / JSR-286 compatible portal, so it is not necessary Liferay tag libs, but those tag libs have been to build to help you.

I would suggest that you study liferay tag-libs, since there are many useful services. If you are looking nice example application take a look https://github.com/liferay-labs/jukebox-portlet.
Meera Prince
RE: is it necessary to use aui tag library
February 5, 2014 6:52 PM
Answer

Meera Prince

Rank: Liferay Legend

Posts: 1110

Join Date: February 8, 2011

Recent Posts

Hi

Here in liferay 6..2 we have xml tag in liferay-portlet.xml i.e <requires-namespaced-parameters/>

with this tag all request parameters should appended with portlet name space then only request parameter consider by portlet action class

when we use <aui:input/> by default the input parameter name appended with portlet name space so that portlet action class will consider..

when we use simple htmp input then input parameter name not appended with portlet name space

so you have two option

option:1 make it false to <requires-namespaced-parameters/> tag in liferay-portlet.xml as follows

<requires-namespaced-parameters>false</requires-namespaced-parameters>

option: 2 add <portlet:namspace/> tag to input name as follows

<input name="<portlet:namspace/>test" id="<portlet:namspace/>test" type="text" value=""/>

Please have a look into http://www.liferaysavvy.com/ for more liferay stuff

Regards,
Meera Prince
Sachin Aware
RE: is it necessary to use aui tag library
February 6, 2014 9:54 AM
Answer

Sachin Aware

Rank: New Member

Posts: 23

Join Date: July 19, 2012

Recent Posts

Thanks meera, it worked by adding <portlet:namspace/> tag to input field.