You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Derek Hohls <dh...@csir.co.za> on 2007/09/07 14:17:51 UTC
Flowscript error on production server
Running Cocoon 2.1.8 - I have an application that works fine
on my local PC and on a test server. When I deploy to a
production server, I get a surprising error when I try to
access a javascript flow routine.
The log file has this entry:
FOM_JavaScriptInterpreter: Function 'main' must have no declared arguments!
Use cocoon.parameters to reach parameters passed from the sitemap into the function.
The sitemap call looks like this:
<map:match pattern="db/*.do">
<map:call function="main">
<map:parameter name="page" value="{1}"/>
</map:call>
</map:match>
and the flowscript function
function main(funName) {
...
}
Why would the flowscript work on one machine but not another?
Are there some deeply buried issues inside Cocoon we do not
know about?!
Any hints, ideas.... or solutions are appreciated!
Thanks
Derek
--
This message is subject to the CSIR's copyright terms and conditions, e-mail legal notice, and implemented Open Document Format (ODF) standard.
The full disclaimer details can be found at http://www.csir.co.za/disclaimer.html.
This message has been scanned for viruses and dangerous content by MailScanner,
and is believed to be clean. MailScanner thanks Transtec Computers for their support.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re: Applet & Cocoon
Posted by johnson <jo...@erp.tw>.
put the applet to template will work.
Best Regards
johnson
Harald Entner ??:
> Hello Folks,
>
> i face the following problem. I have to integrate a signed applet into
> my application.
>
> The sitemap entry looks like:
>
> <!-- applets -->
> <map:match pattern="**.class">
> <map:read src="resource://{1}.class" />
> </map:match>
> The applet is found and returned, but - unfortunately - the dialog if
> i trust the application is not shown.As a result, the following
> exception is thrown:
>
> java.security.AccessControlException: access denied
>
> The template code looks like this:
>
> <applet code="at.workflow.fileTransfer.FileTransferApplet.class"
> archive="SFileTransfer.jar" width="500" height="200">
> <param name="uploadurl"
> value="${cocoon.request.getAttribute('uploadurl')}"/>
> <param name="downloadurl"
> value="${cocoon.request.getAttribute('downloadurl')}"/>
> <param name="filehandler"
> value="${cocoon.request.getAttribute('filehandler')}"/>
> </applet>
>
> The code works, when not run inside cocoon. (via a static html page)
>
> Any suggestions are highly welcome
>
> Harald
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Applet & Cocoon
Posted by Harald Entner <ha...@gmx.at>.
Hello Folks,
i face the following problem. I have to integrate a signed applet into
my application.
The sitemap entry looks like:
<!-- applets -->
<map:match pattern="**.class">
<map:read src="resource://{1}.class" />
</map:match>
The applet is found and returned, but - unfortunately - the dialog if i
trust the application is not shown.As a result, the following exception
is thrown:
java.security.AccessControlException: access denied
The template code looks like this:
<applet code="at.workflow.fileTransfer.FileTransferApplet.class"
archive="SFileTransfer.jar" width="500" height="200">
<param name="uploadurl"
value="${cocoon.request.getAttribute('uploadurl')}"/>
<param name="downloadurl"
value="${cocoon.request.getAttribute('downloadurl')}"/>
<param name="filehandler"
value="${cocoon.request.getAttribute('filehandler')}"/>
</applet>
The code works, when not run inside cocoon. (via a static html page)
Any suggestions are highly welcome
Harald
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re: Flowscript error on production server
Posted by Joerg Heinicke <jo...@gmx.de>.
On 07.09.2007 8:53 Uhr, Derek Hohls wrote:
> No, it IS the same version; that is why I was surprised.
But obviously there ARE differences in your environment as other
messages you posted today show. And the error message here clearly shows
that it is a Cocoon one. This check was added as some particular point.
So it's rather obvious that there are different Cocoon versions
involved, there is no other reasonable explanation for this. Maybe it is
a classpath issue and only the jar versions on the obvious places match.
Joerg
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re: Flowscript error on production server
Posted by Derek Hohls <dh...@csir.co.za>.
Joerg
No, it IS the same version; that is why I was surprised.
I will try the fix you suggest.
Thanks
Derek
>>> Joerg Heinicke <jo...@gmx.de> 2007/09/07 02:29 PM >>>
On 07.09.2007 8:17 Uhr, Derek Hohls wrote:
> Running Cocoon 2.1.8 - I have an application that works fine
> on my local PC and on a test server. When I deploy to a
> production server, I get a surprising error when I try to
> access a javascript flow routine.
>
> The log file has this entry:
>
> FOM_JavaScriptInterpreter: Function 'main' must have no declared arguments!
> Use cocoon.parameters to reach parameters passed from the sitemap into the function.
...
> function main(funName) {
> ...
> }
It should be easy to track down the differences between two machines.
I'd guess it's not the same Cocoon version.
And changing your flowscript code as recommended should work:
function main() {
var funName = cocoon.parameters["funName"];
...
}
The reason for this change was that the order of the parameters (when
having more than once) is just too likely to break.
Joerg
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
--
This message is subject to the CSIR's copyright terms and conditions, e-mail legal notice, and implemented Open Document Format (ODF) standard.
The full disclaimer details can be found at http://www.csir.co.za/disclaimer.html.
This message has been scanned for viruses and dangerous content by MailScanner,
and is believed to be clean. MailScanner thanks Transtec Computers for their support.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re: Flowscript error on production server
Posted by Joerg Heinicke <jo...@gmx.de>.
On 07.09.2007 8:17 Uhr, Derek Hohls wrote:
> Running Cocoon 2.1.8 - I have an application that works fine
> on my local PC and on a test server. When I deploy to a
> production server, I get a surprising error when I try to
> access a javascript flow routine.
>
> The log file has this entry:
>
> FOM_JavaScriptInterpreter: Function 'main' must have no declared arguments!
> Use cocoon.parameters to reach parameters passed from the sitemap into the function.
...
> function main(funName) {
> ...
> }
It should be easy to track down the differences between two machines.
I'd guess it's not the same Cocoon version.
And changing your flowscript code as recommended should work:
function main() {
var funName = cocoon.parameters["funName"];
...
}
The reason for this change was that the order of the parameters (when
having more than once) is just too likely to break.
Joerg
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org