Fórum

how to override create-account.jsp through hook

lokesh gorrela, modificado 7 Anos atrás.

how to override create-account.jsp through hook

Regular Member Postagens: 173 Data de Entrada: 09/03/16 Postagens Recentes
Hi
This is lokesh, I am new to liferay 7.0.1 GA2. My requirement is i have to override a create-account.jsp through hook in liferay 7.0.1 GA2 portal code.Any one knows please tell the procees.

Thanks
Regard's
Lokesh
thumbnail
Danielle Ardon, modificado 7 Anos atrás.

RE: how to override create-account.jsp through hook

Junior Member Postagens: 37 Data de Entrada: 06/06/16 Postagens Recentes
Hi Lokesh,
Have you already read the documentation on overriding core JSP for liferay 7?
https://dev.liferay.com/develop/tutorials/-/knowledge_base/7-0/overriding-core-jsps
-
Danielle
lokesh gorrela, modificado 7 Anos atrás.

RE: how to override create-account.jsp through hook

Regular Member Postagens: 173 Data de Entrada: 09/03/16 Postagens Recentes
Hi Danielle,

I read about OVERRIDING CORE JSPS. But i did not get clarity, Could you plz give suggestion to get clarity about OVERRIDING CORE JSPS.
thumbnail
Marco Endres, modificado 7 Anos atrás.

RE: how to override create-account.jsp through hook

Regular Member Postagens: 112 Data de Entrada: 22/08/12 Postagens Recentes
Hey lokesh

I tried like you to create a hook on Liferay 7.0.1 GA2. I went back to the GA1, because it works there.

Here are some examples:
https://github.com/liferay/liferay-blade-samples

Checkout dev.liferay.com:
https://dev.liferay.com/develop/tutorials/-/knowledge_base/7-0/blade-cli

In Liferay 7 they are called modules and will be made with blade.

Marco
lokesh gorrela, modificado 7 Anos atrás.

RE: how to override create-account.jsp through hook

Regular Member Postagens: 173 Data de Entrada: 09/03/16 Postagens Recentes
Hi Marco,

I tried to overwrite a login.jsp via Module in liferay 7.0.1 GA2. The module is deployed but it doesnt take any effect.

The login.jsp is under the following path:

/blade.hook.jsp/src/main/resources/META-INF/resources/login.jsp

blade.hook.jsp code following this

Bundle-Version: 1.0.6
Fragment-Host: com.liferay.login.web;bundle-version="1.0.6"
-sources: tru
-jsp: *.jsp,*.jspf
-plugin.jsp: com.liferay.ant.bnd.jsp.JspAnalyzerPlugin

could you plz give any suggestion
thumbnail
Marco Endres, modificado 7 Anos atrás.

RE: how to override create-account.jsp through hook

Regular Member Postagens: 112 Data de Entrada: 22/08/12 Postagens Recentes
Hi lokesh

I have problems with the Liferay 7.0.1 GA2. SO i went beack to the GA1.

I think on the Liferay Portal GA2 the com.liferay.login.web Version is "1.0.5". You can check it if you to the gogoshell and type: lb | grep Login

Also you missed the "e" on -sources: true

I asked the similiar questions like you a couple days ago:

https://web.liferay.com/de/community/forums/-/message_boards/message/75981568
https://web.liferay.com/de/community/forums/-/message_boards/message/76221224
http://stackoverflow.com/questions/38117722/liferay-7-jsp-hook-module-doesnt-work/38147535


Hope these links helps emoticon
lokesh gorrela, modificado 7 Anos atrás.

RE: how to override create-account.jsp through hook

Regular Member Postagens: 173 Data de Entrada: 09/03/16 Postagens Recentes
Thank you
lokesh gorrela, modificado 7 Anos atrás.

RE: how to override create-account.jsp through hook

Regular Member Postagens: 173 Data de Entrada: 09/03/16 Postagens Recentes
Hello Marco Endres,

Thank you for your suggestion. I am following your suggestions.I started 7.0.0 GA1 basic setup. Is there any difference between 7.0.0 GA1 to 7.0.1 GA2 for basic setup.If any difference is there please send me detailed steps or any links or any documents.
Thanks
Regards
Lokesh
lokesh gorrela, modificado 7 Anos atrás.

RE: how to override create-account.jsp through hook

Regular Member Postagens: 173 Data de Entrada: 09/03/16 Postagens Recentes
Hi Marco,
Liferay 7.0.0 GA1 setup completed. Can you tell the process of override a login.jsp in liferay 7.0.0 GA1.

Thanks
Regards
Lokesh
lokesh gorrela, modificado 7 Anos atrás.

RE: how to override create-account.jsp through hook

Regular Member Postagens: 173 Data de Entrada: 09/03/16 Postagens Recentes
Hi Marco,

I followed below process to override a hook in liferay 7.0.0 GA1 (In Eclipse IDE)
1)creating a new liferay workspace
file->new->liferay workspace project -> give name of the project (Ex: OSGI)->click to Next -> Finish
2)Click Right button on OSGI->New->Liferay Module Project->give name of the project (Ex: blade.hook.jsp)->click to Next -> Finish
3)expand "blade.hook.jsp" in eclips and open "bnd.bnd" file and paste the blow code

" Bundle-SymbolicName: blade.hook.jsp
Bundle-Version: 1.0.0
Fragment-Host: com.liferay.login.web;bundle-version="1.0.5"
-sources: true
-jsp: *.jsp,*.jspf
-plugin.jsp: com.liferay.ant.bnd.jsp.JspAnalyzerPlugin"

4)create a login.jsp file in this location "bladge.hook.jsp/src/main/resource/META-INF/resource/login.jsp" in eclipse
5)write the code in login.jsp
6)drag the "blade.hook.jsp" into servers
7)Deploy the module following below steps
Gradle Tasks->expand "OSGI"-> expand "build"-> click on "deploy"
8)After deploy get a build success on console
9)verify the result (what you are done the changes that changes effected or not)

Please give replay above process is correct or not.
thumbnail
Marco Endres, modificado 7 Anos atrás.

RE: how to override create-account.jsp through hook

Regular Member Postagens: 112 Data de Entrada: 22/08/12 Postagens Recentes
Hello lokesh

It sounds good. The only things tha is worng, is the Version in the bnd.bnd. On 7.0.0 GA1 is the login-module-version: 1.0.3

Hope now it works

Marco
lokesh gorrela, modificado 7 Anos atrás.

RE: how to override create-account.jsp through hook

Regular Member Postagens: 173 Data de Entrada: 09/03/16 Postagens Recentes
Hello Marco

It's working fine in Liferay 7.0.0 GA1 after changing the version number from 1.0.5 to 1.0.3. Thanks for your helping. But my requirement is override login.jsp in liferay 7.0.1 GA2. I followed same process in Liferay 7.0.1 GA2 and changed the version from 1.0.0 to 1.0.5. But i did not get any change. If you have any knowledge about this issue please help to me.

Thanks,
Regards
Lokesh
lokesh gorrela, modificado 7 Anos atrás.

RE: how to override create-account.jsp through hook

Regular Member Postagens: 173 Data de Entrada: 09/03/16 Postagens Recentes
Hello Marco

Could you please tell the process override a "CreateAccountMVCActionCommand" class from liferay 7.0.1 GA2 portal code.
Thanks
Regards
Lokesh
thumbnail
Marco Endres, modificado 7 Anos atrás.

RE: how to override create-account.jsp through hook

Regular Member Postagens: 112 Data de Entrada: 22/08/12 Postagens Recentes
Hello lokesh

There is a fix out for our jsp problem:

https://web.liferay.com/de/web/jamie.sammons/blog/-/blogs/osgi-module-patching-guide
lokesh gorrela, modificado 7 Anos atrás.

RE: how to override create-account.jsp through hook

Regular Member Postagens: 173 Data de Entrada: 09/03/16 Postagens Recentes
Thank you Marco
One more thing is hook issue resolved in liferay 7.0.1 GA2
Thanks
Regards
Lokesh