meta info in the DCT/TPL?

Options
We have MetaTagger installed correctly (I think?), i.e. "Set Metadata" shows up in the file menu and the capture form pops up ok. Is there any tag you have to put in the individual dct's/.tpl's in order to bring the meta info in? If you generate an html page, shouldn't the meta info you entered with MetaTagger be inserted in the code, or is that something that is added in when the file is deployed out?

Thanks!
maureen

Comments

  • For a given <item> in the iw-home/local/config/datacapture.cfg file which drives the metadata capture form, you must ensure that name attribute maps back a specific <tag> attribute found in metatagger.cfg.

    The fact that these names are the same triggers MetaTagger to automatically populate the form elements. Of course, you have to ensure that metatagger itself is configured to automatically generate the metadata in the first place... eg. you have to ensure that a given <category> in metatagger.cfg maps back to a specific classifier, summarizer, etc. found in .../metatagger/conf. Check out the examples in the .../metatagger/examples directory for an example of how to do this using the classifier (NAICS) that ship with MT.
  • OK, I get that. But if I want this to physically appear in my final html output:
    <META NAME="Description" CONTENT="foo">
    <META NAME="Keywords" CONTENT="bar">
    ...where "foo" and "bar" are dynamically pulled from info entered in the metatagger interface, what is the best way to accomplish this?

    Any thoughts?
    maureen
  • I don't have any 1st hand experience with an implementation, but I was thinking about how to do this when I stumbled over the section on "RCS Macro Expansion" in the TeamSite Adminstration Guide [version 5.0.1, Solaris, pages 146 - 149]

    Looks like it has the capacity to do something like what you're asking.

    Let me know how it goes.

    Tom
  • Tom-
    We figured it out...

    my $eavalue = getEA('/default/...', 'TeamSite/Metdata/...');
    #where /default/... is the path to the html file you want to extract metadata from, and TeamSite/Metadata/... is the specific meta field you want the value from

    sub getEA
    {
    my $file = shift;
    my $eaname = shift;
    my $eacmd;
    my $value;
    my $eaargs;

    if ($eaname)
    {
    $eaargs = "-g \"$eaname\" \"$file\"";
    }
    else
    {
    $eaargs = "$file";
    }

    $eacmd = "$iwhome/bin/iwextattr $eaargs";
    chop( $value = `$eacmd` );

    return $value;
    }

    -maureen
TeamSite Developer Resources

  • Docker Automation

  • LiveSite Content Services (LSCS) REST API

  • Single Page Application (SPA) Modules

  • TeamSite Add-ons

If you are interested in gaining full access to the content, you can register for a My Support account here.
image
OpenText CE Products
TeamSite
APIs