cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brent Johnson <>
Subject Endless Looping in Flow
Date Thu, 28 Oct 2004 20:50:31 GMT
I've got a page where the user can modify something (the title of an
XML document in this case).  Here's what I'm doing in the flowscript:

function showLayoutListPage() {
    var page =;

    if (isLoggedIn()) {

        while (true) {
            cocoon.sendPageAndWait("content/" + page + ".html", {
"page" : page, "user" : cocoon.session.getAttribute("user"), "layouts"
: getLayoutList() });

            var action = cocoon.request.get("doit");
            var filename = cocoon.request.get("filename");

            if (action == "setTitle") {
                // set the title for the layout
                var layout = getLayoutByFilename(filename);

    } else {

So there's an infinite loop there.  Is that going to be a problem? 
See there's really no "end" to this flow.  As long as they're sitting
on the layout manager page they're wanting to "do" something.  The
only end to this continuation would be when they clicked on some other
page rather than clicking "Set Title" or something similar.

Anyone have any thoughts on this?  Will this continually eat up
resources as time goes on or anything?


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message