フォーラム

ホーム » Liferay Portal » English » 3. Development

構造的に表示 平面上に表示 ツリー上に表示
スレッド [ 前へ | 次へ ]
toggle
Imran Khalil
How to autofill Web forms Field ?
2012/10/30 23:50
答え

Imran Khalil

ランク: Junior Member

投稿: 36

参加年月日: 2012/10/21

最近の投稿

Hey All,
I want to know if it is possible to mail the email address of person who is contacting? Like i am login with imran.kahlil and i want that when i navigate to contact us form. The email field is auto filled or in other case just send email address in mail body...

Any Help!
Gaurav Jain
RE: How to autofill Web forms Field ?
2012/10/30 23:56
答え

Gaurav Jain

ランク: Regular Member

投稿: 143

参加年月日: 2011/01/31

最近の投稿

Imran Khalil:
Hey All,
I want to know if it is possible to mail the email address of person who is contacting? Like i am login with imran.kahlil and i want that when i navigate to contact us form. The email field is auto filled or in other case just send email address in mail body...

Any Help!



IMO you can extend web-form portlet (as its an external plugin which can be extended) to meet your requirement.
Infact best way would be to create a new control field - say AutoFillEmail.
And when you keep this type of field in your web-form, it will be automatically filled by the email-id of the logged-in user (ofcourse you have to code this in your extendecd web-form); and for guest users it will still be blank.
Imran Khalil
RE: How to autofill Web forms Field ?
2012/10/31 0:01
答え

Imran Khalil

ランク: Junior Member

投稿: 36

参加年月日: 2012/10/21

最近の投稿

How can i extend it in this way... I was trying but didnt get any success emoticon
Milan Kostoláni
RE: How to autofill Web forms Field ?
2012/11/05 4:53
答え

Milan Kostoláni

ランク: Junior Member

投稿: 92

参加年月日: 2012/07/26

最近の投稿

Hi,

Check the webform portlet source code and EXT tutorial.
Also write your progress, if you need help with it.
Imran Khalil
RE: How to autofill Web forms Field ?
2012/11/06 1:57
答え

Imran Khalil

ランク: Junior Member

投稿: 36

参加年月日: 2012/10/21

最近の投稿

I was trying to do it, But didnt get anything related it.. Can you plz provide me with some links?
Milan Kostoláni
RE: How to autofill Web forms Field ?
2012/11/06 3:34
答え

Milan Kostoláni

ランク: Junior Member

投稿: 92

参加年月日: 2012/07/26

最近の投稿

Check these for EXT : http://www.liferay.com/community/wiki/-/wiki/Main/Development+in+the+ext+environment
http://www.liferay.com/documentation/liferay-portal/6.0/development/-/ai/creating-an-ext-plugin
https://www.liferay.com/community/wiki/-/wiki/Main/Ext+Plugin

and SVN for WebForm: http://svn.liferay.com/repos/public/plugins/branches/6.1.x/portlets/web-form-portlet/
login with guest and no password
Imran Khalil
RE: How to autofill Web forms Field ?
2012/11/06 4:27
答え

Imran Khalil

ランク: Junior Member

投稿: 36

参加年月日: 2012/10/21

最近の投稿

Hi, I had tried but didnt got...

What i actually want is something is like this http://www.liferay.com/request-a-demo form...
Milan Kostoláni
RE: How to autofill Web forms Field ?
2012/11/07 0:45
答え

Milan Kostoláni

ランク: Junior Member

投稿: 92

参加年月日: 2012/07/26

最近の投稿

There is an option that you make your own portlet and just load users information like this
1User u = themeDisplay.getUser();


or that EXT, in which you need to know Web Forms source, well you can just check JSP and remake them
Imran Khalil
RE: How to autofill Web forms Field ?
2012/11/07 1:15
答え

Imran Khalil

ランク: Junior Member

投稿: 36

参加年月日: 2012/10/21

最近の投稿

Milan Kostoláni:
There is an option that you make your own portlet and just load users information like this
1User u = themeDisplay.getUser();


or that EXT, in which you need to know Web Forms source, well you can just check JSP and remake them


Thanks, I am getting to Edit it but I dont have themedisplay there? How can i get user name and email address?
Imran Khalil
RE: How to autofill Web forms Field ?
2012/11/07 1:38
答え

Imran Khalil

ランク: Junior Member

投稿: 36

参加年月日: 2012/10/21

最近の投稿

Thanks alot man,

Got it and Done it emoticon
Milan Kostoláni
RE: How to autofill Web forms Field ?
2012/11/07 3:49
答え

Milan Kostoláni

ランク: Junior Member

投稿: 92

参加年月日: 2012/07/26

最近の投稿

No problem and I think that you had not included init.jsp ( the jsp with all required imports )

BTW Did you created hook/ext or new portlet?
Imran Khalil
RE: How to autofill Web forms Field ?
2012/11/07 3:52
答え

Imran Khalil

ランク: Junior Member

投稿: 36

参加年月日: 2012/10/21

最近の投稿

I had created new portlet with existing source code...

Eclipse showing error in init.jsp file on following line but compiles fine emoticon
<%@ taglib uri="http://liferay.com/tld/aui" prefix="aui" %>