You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by foward <fo...@gmail.com> on 2009/03/20 04:51:43 UTC

Greybox Ajax box with struts2

Hello,

I have one question :), I want to integrate the greybox ajax box (
http://orangoo.com/labs/GreyBox/ http://orangoo.com/labs/GreyBox/  ) with my
webapp in struts2 but appears that in the webserver : 

There is no Action mapped for namespace /scripts/greybox and action name
loader_frame

because the "open window" is called from one html file in the directory
/scripts/greybox/loader_frame.html , how I can make that possible?  ... I
have to exclude something like excludeAction ? please I will appreaciate the
help .

Best Regards
-- 
View this message in context: http://www.nabble.com/Greybox-Ajax-box-with-struts2-tp22613837p22613837.html
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: Greybox Ajax box with struts2

Posted by Chris Pratt <th...@gmail.com>.
The easiest thing might be to just define an action for it.  Something like:

<action name="scripts/greybox/loader_frame">
  <result type="dispatcher">scripts/greybox/loader_frame.html</result>
</action>

might do the trick.
  (*Chris*)

On Thu, Mar 19, 2009 at 8:51 PM, foward <fo...@gmail.com> wrote:

>
> Hello,
>
> I have one question :), I want to integrate the greybox ajax box (
> http://orangoo.com/labs/GreyBox/ http://orangoo.com/labs/GreyBox/  ) with
> my
> webapp in struts2 but appears that in the webserver :
>
> There is no Action mapped for namespace /scripts/greybox and action name
> loader_frame
>
> because the "open window" is called from one html file in the directory
> /scripts/greybox/loader_frame.html , how I can make that possible?  ... I
> have to exclude something like excludeAction ? please I will appreaciate
> the
> help .
>
> Best Regards
> --
> View this message in context:
> http://www.nabble.com/Greybox-Ajax-box-with-struts2-tp22613837p22613837.html
> Sent from the Struts - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>

Re: Greybox Ajax box with struts2

Posted by foward <fo...@gmail.com>.
Hello ,

With yours solutions I change a little the things... because I have all the
actions with the extension "html", I need that, for this reason the more
easy way was change the extension of the file loader_frame.html to
loader_frame.htm ... and the mapping in struts.xml will be :

   <package name="greybox" extends="default" namespace="/scripts/greybox">
            <action name="loader_frame">
              <result
type="dispatcher">/scripts/greybox/loader_frame.htm</result>
            </action>
    </package>

and that works ! ... Thanks again 

Best Regards




-- 
View this message in context: http://www.nabble.com/Greybox-Ajax-box-with-struts2-tp22613837p22643120.html
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: Greybox Ajax box with struts2

Posted by Greg Lindholm <gl...@yahoo.com>.


foward wrote:
> 
> Hello,
> 
> I have one question :), I want to integrate the greybox ajax box (
> http://orangoo.com/labs/GreyBox/ http://orangoo.com/labs/GreyBox/  ) with
> my webapp in struts2 but appears that in the webserver : 
> 
> There is no Action mapped for namespace /scripts/greybox and action name
> loader_frame
> 
> because the "open window" is called from one html file in the directory
> /scripts/greybox/loader_frame.html , how I can make that possible?  ... I
> have to exclude something like excludeAction ? please I will appreaciate
> the help .
> 
> Best Regards
> 

By default struts 2.1.6 treats any url that ends with ".action" OR with no
extension as an action. 
If all your actions end with ".action" and you don't want url's (like
.../scripts/greybox/loader_frame) that have no extension to be treated like
actions then you can change the default action extension to be only
".action". If you add the following to your struts.xml file then url's
without extension will not be treated like actions.

<constant name="struts.action.extension" value="action" />

-- 
View this message in context: http://www.nabble.com/Greybox-Ajax-box-with-struts2-tp22613837p22620966.html
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org