on 11-21-2007 9:15 AM
Hello,
my current task is to modify the default layout of the default Framework Page.
Our page should have a look like this: Example
Is there an easy way to insert such a spacing on the left and right side?
Therefore i need to modify the framework.jsp which defines the Framework Layout.
But my problem is that i am totally a beginner in jsp.
Here my try on this problem.
This is my try for these modifications. I inserted the code that is marked bold.
Would this be a possible solution. And how could i do these modifications on the LAyout for Light Framework? Because the Usage of HTMLB-Tags in Lightframeworks doesn't sound like a good idea.
I think this might be an easy question for you guys. But i don't want to learn the techniques of HTMLB and JSPs from the scratch to do this little modification.
Hope the experts here can help me here with saving lots of time:)
Points will be rewarded for sure if get good answers.
with kind Regards,
Marcus
Message was edited by:
Marcus Böhm
This is htmlb and not really JSP.
I think you need to fill out the empty space with something like this.
<hbj:content id="myContext" >
<hbj:page title="Portal Page">
<hbj:gridLayout id="GridLayout1" width="100%" columnSize="3" rowSize="1" cellSpacing="1">
<hbj:gridLayoutCell rowIndex="1" columnIndex="1" width="10%" >
</hbj:gridLayoutCell>
<hbj:gridLayoutCell rowIndex="1" columnIndex="2" width="80%" horizontalAlignment="center" verticalAlignment="top">
<lyt:container id="FrameworkColumn"></lyt:container>
</hbj:gridLayoutCell>
<hbj:gridLayoutCell rowIndex="1" columnIndex="3" width="10%" >
</hbj:gridLayoutCell>
</hbj:gridLayout>
</hbj:page>
</hbj:content>
this should work.
Code was edited by:
Rasmus Stokholm
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I deployed the new layout successfully and i managed to create a template layout.
Now i wanted to use this layout in the Default Framework Page.
I can choose it as layout but i get this error:
Error in Layout Jsp component (pageId or jspName not available)
Any idea of what could have gone wrong? I think the problem has to be located in the portalapp.xml maybe?
Therefore here the relevant part of the portalpp.xml:
<component name="hccFrame">
<component-config>
<property name="ClassName" Value="com.sapportals.portal.pb.layout.PageLayout"/>
<property name="ResourceBundleName" value="pagebuilder_nls"/>
<property name="SafetyLevel" value="no_safety"/>
</component-config>
<component-profile>
<property name="ComponentType" value="com.sapportals.portal.layout" />
<property name="com.sap.portal.pcm.Title" value="Narrow HCC Frame"/>
<property name="com.sap.portal.pcm.Description" value="Layout displaying one column, that has some spacing to the left and the right side"/>
<property name="com.sap.portal.reserved.layout.TagLibLayout" value="/SERVICE/com.sap.portal.pagebuilder/taglib/layout.tld"/>
<property name="com.sap.portal.reserved.layout.TagLibHtmlb" value="/SERVICE/com.sap.portal.htmlb/taglib/htmlb.tld "/>
<property name="com.sap.portal.reserved.layout.TemplateFile" value="hcc_framework.jsp"/>
<property name="AuthScheme" value="anonymous"/>
<property name="com.sap.portal.reserved.layout.Cont1" value="frameworkColumn">
<property name="title" value="Framework Column"/>
<property name="orientation" value="vertical"/>
<property name="designClass" value="prtlHeaderCon"/>
</property>
</component-profile>
</component>
What does this error mean? Is it possible that the portal is unable to find my framework.jsp?
Thx in advance
Marcus
I guess if you remove the lines which are in bold from portalapp.xml it will work
<component name="hccFrame">
<component-config>
<property name="ClassName" Value="com.sapportals.portal.pb.layout.PageLayout"/>
<property name="ResourceBundleName" value="pagebuilder_nls"/>
<b><property name="SafetyLevel" value="no_safety"/></b>
</component-config>
<component-profile>
<property name="ComponentType" value="com.sapportals.portal.layout" />
<property name="com.sap.portal.pcm.Title" value="Narrow HCC Frame"/>
<property name="com.sap.portal.pcm.Description" value="Layout displaying one column, that has some spacing to the left and the right side"/>
<property name="com.sap.portal.reserved.layout.TagLibLayout" value="/SERVICE/com.sap.portal.pagebuilder/taglib/layout.tld"/>
<property name="com.sap.portal.reserved.layout.TagLibHtmlb" value="/SERVICE/com.sap.portal.htmlb/taglib/htmlb.tld "/>
<property name="com.sap.portal.reserved.layout.TemplateFile" value="hcc_framework.jsp"/>
<b><property name="AuthScheme" value="anonymous"/></b>
<property name="com.sap.portal.reserved.layout.Cont1" value="frameworkColumn">
<property name="title" value="Framework Column"/>
<property name="orientation" value="vertical"/>
<property name="designClass" value="prtlHeaderCon"/>
</property>
</component-profile>
</component>
I think we are getting closer to the problem.
Here my current code version:
protalapp.xml
<application>
<application-config>
<property name="Vendor" value="sap.com"/>
<property name="SecurityArea" value="NetWeaver.Portal"/>
<property name="SharingReference" value="com.sap.portal.htmlb,com.sap.portal.themes.lafservice,com.sap.portal.useragent,com.sap.portal.pagebuilder"/>
</application-config>
<components>
<component name="hccframe">
<component-config>
<property name="ClassName" Value="com.sapportals.portal.pb.layout.PageLayout"/>
<property name="ResourceBundleName" value="pagebuilder_nls"/>
</component-config>
<component-profile>
<property name="ComponentType" value="com.sapportals.portal.layout" />
<property name="com.sap.portal.pcm.Title" value="Narrow HCC Frame"/>
<property name="com.sap.portal.pcm.Description" value="Layout displaying one column, that has some spacing to the left and the right side"/>
<property name="com.sap.portal.reserved.layout.TagLibLayout" value="/SERVICE/com.sap.portal.pagebuilder/taglib/layout.tld"/>
<property name="com.sap.portal.reserved.layout.TagLibHtmlb" value="/SERVICE/com.sap.portal.htmlb/taglib/htmlb.tld "/>
<property name="com.sap.portal.reserved.layout.TemplateFile" value="hccframe.jsp"/>
<property name="com.sap.portal.reserved.layout.Cont1" value="FrameworkColumn">
<property name="title" value="Framework Column"/>
<property name="orientation" value="vertical"/>
<property name="designClass" value="prtlHeaderCon"/>
</property>
</component-profile>
</component>
</components>
<services/>
</application>
Still the old error:
Error in Layout Jsp component (pageId or jspName not available)
null
here my hccframe.jsp
<%@ taglib uri="prt:taglib:com.sap.portal.reserved.layout.TagLibHtmlb" prefix="hbj" %>
<%@ taglib uri="prt:taglib:com.sap.portal.reserved.layout.TagLibLayout" prefix="lyt" %>
<%@ page import="com.sapportals.portal.pb.layout.taglib.variabledef.RunMode" %>
<%
RunMode pageRunMode = null;
%>
<lyt:template>
<%
pageRunMode = epPageVariables.getRunMode();
if(pageRunMode == RunMode.RUN_TIME){
%>
< script>
var scrollLocation=0;
document.body.style.margin=0;
document.body.scroll = "no";
< /script>
<%}%>
<hbj:content id="myContext" >
<hbj:page title="Portal Page">
<hbj:gridLayout id="GridLayout1" width="100%" columnSize="3" rowSize="1" cellSpacing="1">
<hbj:gridLayoutCell rowIndex="1" columnIndex="1" width="10%" >
</hbj:gridLayoutCell>
<hbj:gridLayoutCell rowIndex="1" columnIndex="2" width="80%" horizontalAlignment="center" verticalAlignment="top">
<lyt:container id="FrameworkColumn" />
</hbj:gridLayoutCell>
<hbj:gridLayoutCell rowIndex="1" columnIndex="3" width="10%" >
</hbj:gridLayoutCell>
</hbj:gridLayout>
</hbj:page>
</hbj:content>
</lyt:template>
<%
if(pageRunMode == RunMode.RUN_TIME){
%>
< script>
// Set the Top Level Navigation iView size and position.
EPCM.raiseEvent("urn:com.sapportals:toplevelnavigation", "Onload", null);
</ script>
<%}%>
Hi Marcus
I'm not quite sure what you start with in your portalapp.xml
But i think i would start from scratch, so you dont have to modify it.
download the
com.sap.portal.layouts.framework.par
and change the framework.jsp with the changes from the original question.
Afterwards deploy the file with a new name like
com.yourcompany.portal.layouts.framework.par
then follow step 5.3 in this guide
This should enable you to create a new framework page with out changing the portalapp.xml.
Afterwards you can connect your new framework page to a portal desktop.
GL Rasmus
I have tried it this way.
But when i create a new layout the archive com.yourcompany.portal.layouts.framework.par isn't available as choice -.-
Don't know what i have. I imported the par and changend the .jsp.
I think i will try again after weekend. This is a bad day ;( .
Can you maybe test it yourself?
Regards,
Marcus
Hi Marcus Böhm, I have the same problem in one Portal 7.0 SP9, but in EP 7.0 SP13, 14 or 15 the same layout framework running without errors, what are your SP?
Fabrício Stein
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
this custom layout in portalapp.xml works for us:
<component name="DTN_Content_Layout">
<component-config>
<property name="ClassName" value="com.sapportals.portal.pb.layout.PageLayout"/>
<property name="ResourceBundleName" value="pagebuilder_nls"/>
</component-config>
<component-profile>
<property name="AuthScheme" value="anonymous"/>
<property name="EPCFLevel" value="0"/>
<property name="com.sap.portal.pcm.Title" value="DTN and Content page layout"/>
<property name="ComponentType" value="com.sapportals.portal.layout"/>
<property name="LayoutTagLibrary" value="/SERVICE/com.sap.portal.pagebuilder/taglib/layout.tld"/>
<property name="com.sap.portal.reserved.layout.TemplateFile" value="dtn_content.jsp"/>
<property name="com.sap.portal.reserved.layout.Cont1" value="navigation_container">
<property name="plainDescription" value="Navigation Page Area"/>
<property name="orientation" value="vertical"/>
<property name="CachingLevel" value="none"/>
<property name="ValidityPeriod" value="0"/>
</property>
<property name="com.sap.portal.reserved.layout.Cont2" value="content_container">
<property name="plainDescription" value="Content Page Area"/>
<property name="orientation" value="vertical"/>
<property name="CachingLevel" value="none"/>
<property name="ValidityPeriod" value="0"/>
</property>
</component-profile>
</component>
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
80 | |
9 | |
9 | |
7 | |
7 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.