Solved

Page Layout Help

Posted on 2012-03-26
9
898 Views
Last Modified: 2012-03-26
Hello All,

I created a page layout in SharePoint Designer 2010, saved it and checked it in then approved it.

When I create a new page in SP 2010 and I apply my new page layout, I get the first image you see attached.  As you can see, all my field controls appear and I'm able to insert data into it.
When I save and close, I get the 2nd image, which shows data from only one field.  The rest don't even show up.

Please help!  I've been dealing with this since last night and I'm getting frustrated.
What am I doing wrong?

Thanks for any help you can provide.
pgLayout1.PNG
pgLayout2.PNG
0
Comment
Question by:Isaac
  • 5
  • 4
9 Comments
 
LVL 11

Expert Comment

by:svetaye
ID: 37767689
Hello,
Are you ure that your custom fields don't have Visisble="False" attribute and rhey are not a part of Edit Mode Panel?

Can you post the code of the file here?

Thank you.
0
 
LVL 5

Author Comment

by:Isaac
ID: 37767930
Here you go....


<%@ Page language="C#"   Inherits="Microsoft.SharePoint.Publishing.PublishingLayoutPage,Microsoft.SharePoint.Publishing,Version=14.0.0.0,Culture=neutral,PublicKeyToken=71e9bce111e9429c" meta:progid="SharePoint.WebPartPage.Document" meta:webpartpageexpansion="full" %>
<%@ Register Tagprefix="SharePointWebControls" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> <%@ Register Tagprefix="WebPartPages" Namespace="Microsoft.SharePoint.WebPartPages" Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> <%@ Register Tagprefix="PublishingWebControls" Namespace="Microsoft.SharePoint.Publishing.WebControls" Assembly="Microsoft.SharePoint.Publishing, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> <%@ Register Tagprefix="PublishingNavigation" Namespace="Microsoft.SharePoint.Publishing.Navigation" Assembly="Microsoft.SharePoint.Publishing, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<asp:Content ContentPlaceholderID="PlaceHolderPageTitle" runat="server">
      <SharePointWebControls:FieldValue id="PageTitle" FieldName="Title" runat="server"/>
</asp:Content>
<asp:Content ContentPlaceholderID="PlaceHolderMain" runat="server">
<table style="width: 100%">
      <tr>
            <td colspan="2">
            <PublishingWebControls:EditModePanel runat="server" id="EditModePanel1">
            <SharePointWebControls:TextField FieldName="fa564e0f-0c70-4ab9-b863-0177e6ddd247" runat="server" id="TextField1">
            </SharePointWebControls:TextField>
            </PublishingWebControls:EditModePanel>            
            </td>
      </tr>
      <tr>
            <td rowspan="4">
            <PublishingWebControls:RichHtmlField FieldName="f55c4d88-1f2e-4ad9-aaa8-819af4ee7ee8" runat="server" id="RichHtmlField1">
            </PublishingWebControls:RichHtmlField>
            </td>
            <td>
            <PublishingWebControls:EditModePanel runat="server" id="EditModePanel2">
            <SharePointWebControls:TextField FieldName="83fd7a94-7a29-4726-95ea-6916daf87f3d" runat="server" id="TextField2">
            </SharePointWebControls:TextField>
            </PublishingWebControls:EditModePanel>
            </td>
      </tr>
      <tr>
            <td>
            <PublishingWebControls:EditModePanel runat="server" id="EditModePanel3">
            <SharePointWebControls:TextField FieldName="667a45bc-6066-4f42-8d53-9162768ab5ee" runat="server" id="TextField3">
            </SharePointWebControls:TextField>
            </PublishingWebControls:EditModePanel>
            </td>
      </tr>
      <tr>
            <td>
            <PublishingWebControls:EditModePanel runat="server" id="EditModePanel4">
            <SharePointWebControls:TextField FieldName="2c25a7e2-88dc-47f5-bca1-2e19f798eb78" runat="server" id="TextField4">
            </SharePointWebControls:TextField>
            </PublishingWebControls:EditModePanel>
            </td>
      </tr>
      <tr>
            <td>
            <PublishingWebControls:EditModePanel runat="server" id="EditModePanel5">
            <SharePointWebControls:TextField FieldName="20be92fb-f628-4dc2-8d05-23ed57527330" runat="server" id="TextField5">
            </SharePointWebControls:TextField>
            </PublishingWebControls:EditModePanel>
            </td>
      </tr>
</table>
</asp:Content>
0
 
LVL 11

Accepted Solution

by:
svetaye earned 500 total points
ID: 37768087
Ok, here is the issue. All your fields are inside the Edit Mode panels.
Put fields outside the Edit Mode panel controls.Edit Mode Panel is visible only in the edit mode.
And I'm not sure that your changes will be saved to the page fields, but first try to delete Edit Mode Panels.
0
Ransomware: The New Cyber Threat & How to Stop It

This infographic explains ransomware, type of malware that blocks access to your files or your systems and holds them hostage until a ransom is paid. It also examines the different types of ransomware and explains what you can do to thwart this sinister online threat.  

 
LVL 5

Author Comment

by:Isaac
ID: 37768156
Really?  but the editmodelpanel has a opening and closing tag.  

I will give that a try.
0
 
LVL 11

Expert Comment

by:svetaye
ID: 37768180
Yes, it have a closing tag but after the textbox control. It contains the textbox and hide it in the Display mode.
0
 
LVL 5

Author Comment

by:Isaac
ID: 37768278
Ok.  That worked.  I was hoping that the editmodepanel would make my field control look like the this...
panel
I thought that's what it did but apparently not.

So, how do I make it look like the above and what does the editmodepanel do?

This does not make sense....
            <PublishingWebControls:EditModePanel runat="server" id="EditModePanel2">
            </PublishingWebControls:EditModePanel>
            <SharePointWebControls:TextField FieldName="83fd7a94-7a29-4726-95ea-6916daf87f3d" runat="server" id="TextField2">
            </SharePointWebControls:TextField>
0
 
LVL 5

Author Comment

by:Isaac
ID: 37768284
The embeded image in my last post was the default page layout.
0
 
LVL 11

Expert Comment

by:svetaye
ID: 37768317
OK, I think you are missing some basic idea of the Edit Mode Panel and fields.
Please take a look at this article:
"In SharePoint 2010, an Edit mode panel is visible only in, well, publishing page Edit mode. That makes this panel great for all kinds of information or properties that are helpful to your editors but that you don’t want visible when the page is in Read mode."

http://www.dummies.com/how-to/content/edit-mode-panel-in-sharepoint-2010.html

Now about the Publishing Rich text control : you need to use some existing column of the Page Content type and not some disconnected control.
Please take a look at this tutorial:
http://www.dotnetcurry.com/ShowArticle.aspx?ID=638
0
 
LVL 5

Author Closing Comment

by:Isaac
ID: 37768335
Thanks!
0

Featured Post

Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Last week I faced a strange issue recently, i have deployed SharePoint 2003 servers for one project and one of the requirements was to open SharePoint site from same server. when i was trying to open site from the same server i was getting authentic…
The vision: A MegaMenu for a SharePoint portal home page The mission: Make it easy to maintain. Allow rich content and sub headers as well as standard links. Factor in frequent changes without involving developers or a lengthy Dev/Test/Prod rel…
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question