You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by "Bruyn, Bill-p6141c" <Bi...@gdc4s.com> on 2007/04/23 21:08:01 UTC

[s2] struts2-portlet-2.0.6 example

Hi all,
 
Is the Ajax example bundled with struts2-portlet-2.0.6 example app
supposed to work out of the box?  I've deployed to WebLogic 9.2, and
seem to have at least a few problems with it:
 
1.  Tags containing 'nested' quotation marks yield some sort of
"attribute not recgnized" error.  e.g.,  href="<s:url
action="ajaxData"/>" is a problem, so I switched that to an el
expression as illustrated in the documentation:  

        <s:url id="ajaxExampleAction" action="ajaxData" />

        href="%{ajaxExampleAction}"

which seems to work, except that

 

2.  The inclusion of the Ajax result on more than one place crashes my
IE 6.0 browser pretty consistently (I don't have another browser to test
with yet, unfortunately).  e.g.,

        <s:div id="once" href="%{ajaxExampleAction}" ...>

        <s:div id="twice" href="%{ajaxExampleAction}" ...>

is a problem.  Hacked the example to include just a single ajax-enabled
div and

 

3.  it all seems to work, except that the portal has aggregated the
content instead of allowing the browser to do it in-place.  i.e., the
ajaxData.jsp content is surrounded by portal markup (title bar, window
state controls, etc.) which is clearly not the desired result.

I've fooled around a bit with the configuration, but I have to say that
I'm relatively new to both Struts and Portlets, and have so far not been
able to get the results I expected.  Appreicate any help I can get.

 

TIA,

Bill Bruyn

(BTW, the Velocity example doesn't seem to work either, although the
resource in question is in fact where it's supposed to be:
org.apache.velocity.exception.ResourceNotFoundException: Unable to find
resource '/WEB-INF/view/helloWorld.vm')