You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by This High Xvision <th...@yahoo.com> on 2006/12/12 18:29:37 UTC

Tapestry Component using another Component (in this case JSCookMenu)

Hi!

I've build a Home page with the JsCookMenu. No
problems doing so, it 
works according to the example of the JSCookMenu site.

The problem is that instad of using the Jscookmenu on
the Home page, 
I've built Border component, where on the HTML
template page I've put 
the jscookmenu.

Well I'm unable to make it work...

My .JWC file:

<component-specification>
  <asset
path="classpath:/com/part/tapestry/start-menu.xml" 
name="xmlModel" />
  <parameter name="source" property="menuModel"
></parameter>
  <parameter name="value" property="menuItem"
></parameter>
  <parameter name="theme"
default-value="Office2003"></parameter>
  <parameter name="position" default-value="hbr"
></parameter>
</component-specification>

My HTML file:

<html>
<head></head>
<body jwcid="@Body">
    <table border="0" width="100%">
        <thead>
            <tr>
   <th>
   <span jwcid="@menu:JSCookMenu"
source="ognl:menuModel" 
value="ognl:menuItem" theme="Office2003"
position="hbr" 
effect="CMSlidingEffect(8)">
       <a href="#" jwcid="contentRenderer@DirectLink" 
listener="listener:onNavigate"
parameters="ognl:menuItem.value" >
              <span jwcid="@Insert"
value="ognl:menuItem.value"/>
          </a>
      </span>
   </th>

The Java page is the one from the jscookmenu site for
the JSCookMenu 
component.

So there is no error, but the menu doesn't render.

<html>
<head></head>

<body>
<script type="text/javascript"
src="/apliapp/app?digest=b190e8e8797dfda62ef63c45592706e8&amp;service=asset&amp;path=%2FJSCookMenu-mod.js"></script>
<script type="text/javascript"
src="/apliapp/app?digest=10368912e50baa9b12ed0b1e8d94e0ed&amp;service=asset&amp;path=%2FLinkDecorator.js"></script>
<script type="text/javascript"
src="/apliapp/app?digest=a70eeb758ec04c69dcc4b45f4a31c8da&amp;service=asset&amp;path=%2Feffect.js"></script>
<script type="text/javascript"><!--
var NPHome__Border__JSCookMenu_divId = new Object();
NPHome__Border__JSCookMenu_divId['effect'] = new
CMSlidingEffect(8);

// --></script>
    <table border="0" width="100%">

        <thead>
            <tr>
   <th> 
   <link rel="stylesheet"
href="/apliapp/app?resType=css&service=jscooktheme&theme=Office2003&timestamp=1165944336111"
type="text/css"/>
<script type="text/javascript"
src="/apliapp/app?resType=js&amp;service=jscooktheme&amp;theme=Office2003&amp;timestamp=1165944336111"></script>
<div id="Home__Border__JSCookMenu_divId"><ul
style="visibility: hidden;"></ul></div>
<script type="text/javascript"><!-- 
themeOffice2003_Draw('Home__Border__JSCookMenu_divId',
'hbr', NPHome__Border__JSCookMenu_divId, null, null,
null, '1165944382427');
// --></script>
   </th>

It seems that the page doesn't find the resources
needed to render the menu.

Do I need to put something on the component
specification regarding the Jscookmenu assets?

Any ideas, tips?

Thanks!























 
____________________________________________________________________________________
Do you Yahoo!?
Everyone is raving about the all-new Yahoo! Mail beta.
http://new.mail.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org