Pages

Showing posts with label Page lay-out. Show all posts
Showing posts with label Page lay-out. Show all posts

Wednesday, March 7, 2012

SharePoint 2010 - Page lay-out and Managed Metadata column

I was having issues with a new page lay-out and displaying a managed metadata column. The column got displayed like this:

CustomTag_0:TaxonomyFieldControl

This prevented my page to load correctly. I found this great article from Dave Perkinson:

http://underthehood.ironworks.com/2010/03/sharepoint-2010-how-tos-embedding-managed-metadata-page-fields-in-your-page-layouts.html

The problem is that your page layout is missing the requisite assembly reference to include the Taxonomy Picker control. You can fix this problem by adding the following reference to the top of your page layout:

<%@ Register Tagprefix="Taxonomy" Namespace="Microsoft.SharePoint.Taxonomy" Assembly="Microsoft.SharePoint.Taxonomy, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>"

This worked like a charm! Thanks Dave :-)

I also found the following solution:
http://blog.degree.no/2011/01/sharepoint-2010-adding-taxonomyfieldcontrol-to-custom-page-layout/


<%@ Register Tagprefix="Taxonomy" Namespace="Microsoft.SharePoint.Taxonomy" Assembly="Microsoft.SharePoint.Taxonomy, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
Then change the <CustomTag_0:TaxonomyFieldControl> to <Taxonomy:TaxonomyFieldControl> and off you go (remember there is a closing tag too, by the way..):
<Taxonomy:TaxonomyFieldControl FieldName="81d247d1-0373-4a2d-9e81-d4b69bf3e091" runat="server"></Taxonomy:TaxonomyFieldControl>

Friday, February 10, 2012

SharePoint 2010 - Page lay-out example

My colleaguea Danny Korf helped me out today by creating a page lay-out:


You can recreate this by using the following code:

<div class="w-webpartzoneWrapper">
<div class="w-webpartzoneWrap">
<div class="w-webpartzoneContainer">
ENTER WEBPARTZONE
</div>
<div style="clear:both;"></div>
<div class="w-webpartzoneContainer">
ENTER WEBPARTZONE
</div>
</div>
<div class="w-webpartzoneWrap">
<div class="w-webpartzoneContainer">
 ENTER WEBPARTZONE
</div>
<div style="clear:both;"></div>
<div class="w-webpartzoneContainer">
                  ENTER WEBPARTZONE
</div>
</div>
<div class="w-webpartzoneWrap">
<div class="w-webpartzoneContainer">
                 ENTER WEBPARTZONE
</div>
<div style="clear:both;"></div>
<div class="w-webpartzoneContainer">
                ENTER WEBPARTZONE
</div>
</div>
</div>


Wednesday, October 12, 2011

SharePoint 2010 - Page lay-out with three web part zones

Hi,

I created a page lay-out, with the help of my colleague Danny Korf, with three webpartzones:

The code for this page lay-out is the following:


<div style="width:100%;height:100%;">
<div style="position:relative;float:left;width:80%;padding:10px 20px 20px 10px;">
<WebPartPages:WebPartZone id="g_9F6060BB53E14B92ADA9598308474340" runat="server" title="Topzone"></WebPartPages:WebPartZone>
</div>
</div>
<div style="width:100%;height:100%;">
<div style="position:relative;float:left;width:40%;padding:10px 20px 0px 10px;">
<WebPartPages:WebPartZone id="g_6D19E20134854269A80FCDA20AB4640B" runat="server" title="Linker zone"><ZoneTemplate></ZoneTemplate></WebPartPages:WebPartZone>
</div>
<div style="position:relative;float:left;width:40%;padding:10px 20px 0px 10px;">
<WebPartPages:WebPartZone id="g_DC89797E58FE481EA912950ACCBB2EB0" runat="server" title="Rechter zone"></WebPartPages:WebPartZone>
</div>
</div>

You only have to remove the WebpartPages and add your own webpartzone there.

Hope this can be helpful.