Foros de discusión

HTML Decrations are not working in Liferay

Kiran Jai, modificado hace 12 años.

HTML Decrations are not working in Liferay

Junior Member Mensajes: 38 Fecha de incorporación: 9/04/12 Mensajes recientes
I am using Liferay 6 with Struts2 . I have this Struts2 Tags JSP in Liferay .

<HTML>
<HEAD>
<TITLE>Login using Ravi</TITLE>
</HEAD>
<body bgcolor="#E6E6FA">
<s:form action="helloForm" method="POST" theme="simple">
<table>
<tr>
<td>Enter Your Name:<s:textfield name="namer" value="%{name}" required="true"/></tr>td>
</tr>
<tr>
<td>Enter Your Password:<s:textfield name="passer" value="%{passer}" /></tr>td>
</tr>
</table>
<s:submit/>
<s:submit/>
<s:submit/>
</s:form>
</BODY>
</HTML>

This page is being displayed , but the issue is that , the body color is not being chnaged at all . And also when i tried to set the body height width and all they are not being reflected .

Or is it that using themes only we can achieve this ?
thumbnail
Hitoshi Ozawa, modificado hace 12 años.

RE: HTML Decrations are not working in Liferay

Liferay Legend Mensajes: 7942 Fecha de incorporación: 24/03/10 Mensajes recientes
Have you tried using <body style="background-color:black;"> ? Should be using "style" and css nowadays.
Kiran Jai, modificado hace 12 años.

RE: HTML Decrations are not working in Liferay

Junior Member Mensajes: 38 Fecha de incorporación: 9/04/12 Mensajes recientes
Hitoshi Ozawa:
Have you tried using <body style="background-color:black;"> ? Should be using "style" and css nowadays.



Ya , It worked with that . agree that should use css nowadays , but still the question why the tradational way isn't working ??.
thumbnail
David H Nebinger, modificado hace 12 años.

RE: HTML Decrations are not working in Liferay

Liferay Legend Mensajes: 14919 Fecha de incorporación: 2/09/06 Mensajes recientes
Because even though you're page thinks it's generating a whole HTML page, Liferay is going to only grab the content in order to aggregate a whole portal page. So body styling that you use in the jsp page is effectively ignored.

You're not in Kansas any more, Dorothy...
thumbnail
Hitoshi Ozawa, modificado hace 12 años.

RE: HTML Decrations are not working in Liferay

Liferay Legend Mensajes: 7942 Fecha de incorporación: 24/03/10 Mensajes recientes
As David replied, if you look at the souce code of the generated page, you'll see that the entire page is just one html. Liferay is actually converting codes in a portlet to fit in one html page. Since there should only be one body per html, you really shouldn't be putting body tags in portlets because a html page should only have one header and one body.