Effective Placeholder Use

There are many ways to implement CMS. As a result, there are wide variations in how developers and designers use placeholders. We've compiled a short list of best practices for using placeholders within your templates.

  • Try to limit the number of placeholders on your template. There's sometimes a tendency to add lots of placeholders to account for the various elements of a page. For example, if you wanted a page with 20 images and 20 blocks of text, you'd end up with 40 placeholders on a page. Although this is technically possible to do, it not only presents a poor user interface, it will affect page render performance. As an alternative, consider creating a detail-summary relationship. For each image and text block on the page, create a detail posting. Then create a summary page that consolidates all of the image/text posting content into one page. Not only will this improve content contribution, but it will promote content reuse and improve site performance. To prevent all these postings from showing up in the navigation, make them hidden postings, or place them in a hidden channel. Also, consider creating a Web Author task-based publishing link in the edit console to add additional text/image pair postings. See Chapter 36 for more information on Web Author task-based publishing.

  • Don't stick "one big" placeholder on your templates, allowing content contributors to just throw anything in it. Not only does this particular methodology provide the opportunity for poor content practices and poor design, it may be frustrating to your content contributors. Consider componentizing your content into separate placeholders, each with a specific purpose. Allow each placeholder to accept only specific types of content.

  • Don't be afraid to access content in placeholders programmatically. A lot of novice template developers think that where the placeholder is situated is where the content should render. This is really not the case. For a whole host of reasons, you may want to render the content differently from the way the placeholders are laid out. For example, if you want to render an image within a block of text, wrapping the text around the image, it may be impractical to place the image placeholder next to the HTML placeholder. Instead, consider placing the image placeholder first and then the HTML placeholder directly underneath. This arrangement makes much more sense from a contributor perspective. Then, when the page renders, hide the actual placeholder controls. You can grab the content and render it programmatically in the way that makes sense for your page.

  • Size your placeholders properly. It sounds like a simple guideline, but the size of a placeholder will suggest the amount of content to be contributed. Content contributors will look at a large placeholder and try to contribute a large amount of content. Conversely, a smaller placeholder will suggest that less content should be contributed. One example of this behavior is the use of a placeholder for the title of a page. If you size the title placeholder too large, content contributors think they can provide a lot of content, even though the actual space provided for the content is relatively small.

  • Just because you have content on a posting, it doesn't mean that you need a placeholder. Content on a posting could be coming from another posting, a database, or a placeholder. Consider carefully where your content is coming from before you place another placeholder on the template.

  • If you have multiple placeholders on a page, make sure that the instructions on the placeholders are clear and concise. It is important that all the authors use the placeholders in a consistent way for future maintenance on the template. Using labels over the placeholders and/or default text will help ensure that authors know what each placeholder is supposed to contain.



Microsoft Content Management Server 2002. A Complete Guide
Microsoft Content Management Server 2002: A Complete Guide
ISBN: 0321194446
EAN: 2147483647
Year: 2003
Pages: 298

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net