Editable Meta Data with Macromedia Contribute
One issue that is sometimes raised on the Macromedia forums is how to make the meta data of each page unique when using Dreamweaver MX templates in conjunction with Contribute. With Dreamweaver MX this is no problem whether you use templates or not, but what if the client wants to use Contribute to maintain their own site? What do you do for them?
To explore this a bit, imagine this scenario: you've been contacted by a prospective client who wants you to build their web site. This client specifies the following as design elements and requirements (yeah... sure... don't you wish the client was always like this!)
Design Elements & Requirements:
- Must use templates for consistent design site wide;
- Each page must have customizable Meta Data for the Meta Tags specified;
- The site must be easily maintainable using Macromedia Contribute.
Your options:
- You can make a custom new page for the client to use in Contribute. Details of performing this function are located in Technote 16601 at the Macromedia Contribute support site. The problem with this option is that although *you* can customize the initial meta data using DMX, you still cannot customize the meta data through Contribute (since it is in the head of the document, and you would need code-level access to get at it).
- You can include the meta data as an SSI (Server-side Include) and use template parameters and expressions to attach a different include (containing unique meta tags & content) to each child page. This option does allow you to have unique meta data control on each page, but also requires the use of a separate include for each page, as well as the mechanical issue of having to train your Contribute users in how to access each page's specific include, so it isn't a very trouble-free resolution to the problem at hand.
- Use Dreamweaver MX templates, parameters and expressions to control the individual meta data contents. This option requires the site to use templates (as specified in the requirements), and that the Contribute user group have access to this template.
The latter option is the method we will be discussing below.
Keywords & Description meta tags
If you want Contribute to be able to edit Keywords and Description meta data, then these meta tags need to be in an editable region in the head (other than doctitle). If these two meta data types are not in an editable region, then they will not be able to be made unique on each page and Contribute won't be able to edit them.
Other meta data tags
Other meta data tags can be made editable as well with relative ease following these simple steps (we are using a different method here because Contribute has no user interface for changing meta tags *other* than keywords and description using: Format » Keywords and Description...).
- Any additional meta tags that you want to be editable must not be in an editable region because you will use parameters and expressions to designate their editability.
- Add a text type parameter for each editable meta data tag.
<!-- TemplateParam name="META_Author" type="text" content="your name" --> - Modify your meta data tag to use an expression for the content. The expression in this case is simply the parameter that you designated above.
<meta name="author" content="@@(META_Author)@@"> - Save the template and update the pages.
- If you've put these same meta data tags in an editable region previously, they must be deleted using either a sitewide search and replace or by manually removing them from each page based on this newly modified template.
- The user editing the child page(s) would use the following menu item to change the content of the parameters previously specified:
Dreamweaver MX users: Modify» Template Properties...
Contribute users: Format» Template Properties...
Now your meta data is user editable with both Dreamweaver MX and Contribute and can be made unique on each and every page with much less aggravation.
Downloads:
Working files for you to download are available here: MetaData.zip