You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Enrico Migliore <en...@fatti.com> on 2004/05/15 11:48:16 UTC

added: cocoon.request.getRequestURI()

Hi guys,


fact
-------
 I added the following function to Cocoon:
                       "cocoon.request.getRequestURI( )"
in order to access the URI of the request from the Flow

                                 ---oOo---

how-to
-------
1. open "FOM_Cocoon.java" source file
2. Find the following class:
        public static class FOM_Request extends ScriptableObject {
         ......  
        }
3. add the following method to that class:
         public String jsFunction_getRequestURI( ) {
            return request.getRequestURI( );
        }
4. rebuild Cocoon

                                 ---oOo---

test
----
just add:  "System.out.println("URI = " + cocoon.request.getRequestURI( ));"
to your Flow/Javascript code and you'll see on the standard output the 
URI of
the client's request


many other functions can be added in this way.
 Enrico

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