I am working on implementing shindig as an opensocial container, and I
am having some trouble with os templates and data pipelining.  I have
been working on a gadget definition based on the spec
(http://wiki.opensocial-templates.org/index.php?title=OpenSocial_Data_Pi
pelining) but I keep getting the same error message on the console
(Warning: Cannot resolve identifier viewer).  Here is my gadget
definition:

 

<?xml version="1.0" encoding="UTF-8"?>

<Module>

 <ModulePrefs title="Basic Gadget">

   <Require feature="opensocial-0.8"></Require>

   <Require feature="dynamic-height"></Require>

   <Require feature="opensocial-data"></Require>

   <Require feature="opensocial-data-context"></Require>

   <Require feature="opensocial-templates"></Require>

   <Require feature="xmlutil"></Require>

   <Optional feature="content-rewrite">

        <Param name="include-tags"></Param>

   </Optional>

 </ModulePrefs>

 <Content type="html" xmlns:os="http://ns.opensocial.org/2008/markup";>

   <![CDATA[  

        <script type="text/os-data">

            <os:PersonRequest key="viewer" id="VIEWER"/>

        </script>

        <script type="text/os-template">

            <b>Hello ${viewer.displayName}</b><br>

        </script>

   ]]>

  </Content>

</Module>

 

The template is being displayed with just "Hello" and then nothing.
Hopefully I am just missing something silly.

 

Also, do I need to Require all of those features?  The opensocial-data
feature appears to have a dependency on opensocial-data-context ,
opensocial-0.8, and xmlutil.  Does that mean those features are
automatically included in my feature if I Require opensocial-data.  I
couldn't find anything about the dependency tag in the gadget container
spec.

 

(I am working on the source from the trunk in svn)

 

If anyone has some resources I can take a look at with regards to
opensocial templates and data pipelining, that would be helpful too.

 

Thanks

 

Steve

 

Reply via email to