SharePoint 2010: Add a WebPartZone to a Team Site

Have you tried to add a webpartzone to a SharPoint 2010 Team Site page in SPD? You can, but you will find that you cannot add webparts to the zone in the browser. In my opinion this partly defeats the purpose of adding a webpart zone in the first place. But wait, there is really good news!
You probably do not need to add webpart zones to a team site in SharePoint 2010. Why? Well, Team Sites in SharePoint 2010 use a wiki content div which allows you to add web parts directly inline with text in the different zones created in the layout you choose.
If you open up a content page in SPD, look for the following code block:

<SharePoint:EmbeddedFormField id="WikiField" FieldName="WikiField" ControlMode="Display" runat="server">
<div>...
<span id="layoutsData" style="display:none">true,true,3</span>
</div>
</SharePoint:EmbeddedFormField>

This is where the magic happens. SharePoint’s EmbeddeFormField tag inserts a Wiki control into the page in question. The “content” of the control will go where the … are.  What about the span, <span id=”layoutsData” style=”display:none”>true,true,3</span>? This defines the layout of the control. The first boolean value is if a header should be included, the second boolean sets if a footer should be included and the number can be between 1 and 3, which defines how many columns are included. In the example provided,  (header, footer, 3 col). Side note, I have been told quite a few times that there are the only layout options available. If it’s possible to add more layout options, it’s not easy.
What is really cool is that with these layout options and that fact that you can add html, css and webparts all inline with content, you can get almost any layout you want with any mixture of webparts and text, all updatable via a web browser.
Nice huh?

Leave a Comment

Your email address will not be published. Required fields are marked *

Enter Code *

Filed Under

Related

Are you preparing to launch a new #SharePoint intranet?

Don’t spring it on employees out of the blue. First, talk to as many of them as you can.

Planning is just phase one. For all of our tips, watch our recent webinar!

http://ow.ly/dsQM50GqPI5

It's that time again! Join #Microsoft MVP & Regional Director, @EricOverfield on Thursday, October 28th, at 11:00 AM PST as he walks through #MicrosoftViva’s current state & offerings and what they mean to your #digitalworkspace right now.

http://ow.ly/3QFK50Gnx9f

It's the final countdown! Join @EricOverfield at 11am PST to learn about common pitfalls and paths to success when moving to #SharePointOnline. You'll walk away with practical tips to use in your organization today!

http://ow.ly/fdf150GjyJT

In today's episode of the #PixelMillWebinars, you'll learn from the experience of a global organization’s path to digital teamwork victory and get to see first-hand how to successfully plan a smooth migration for your team.

Join us at 11am PST!

https://pixelmill.com/webinar-9-takeaways-from-a-global-organizations-migration-to-sharepoint-online/

It's the day of the show y'all! Join #Microsoft RD +MVP @EricOverfield at 11am PST as we walk you through a multi-national enterprise software company’s migration journey to #SharePointOnline. Learn about common pitfalls and paths to success.

http://ow.ly/cN9250GjtGk

Subscribe to PixelMill's
E-news

* indicates required

Let's Talk Digital
Workspaces Today

Get In Touch