Session.message with res.redirect()
"Austin, Tom" <[email protected]> Thu, 24 Jan 2008 19:02:28 -0800
| Newsgroups | gmane.comp.java.helma.general |
|---|---|
| Message-ID | <[email protected]> |
Hi,
I've been running into some problems with session.message. It does not
seem to survive res.redirect(). I see a similar issue at
http://www.helma.org/bugs/show_bug.cgi?id=245, but that looks like it is
fairly old.
Does anyone have any ideas what I'm doing wrong? If I remove the
redirect, the message will display OK. I'm using Helma v. 1.6.1.
Here are the files I have:
::::::::::::::
apps/test/Root/enter_message.hac
::::::::::::::
if (req.isPost()) {
session.message = "***" + req.data.message_text + "<br />";
res.redirect(root.href());
}
renderSkin('enter_message');
::::::::::::::
apps/test/Global/enter_message.skin
::::::::::::::
<html>
<head>
<title>Enter a message</title>
</head>
<body>
<% response.message %>
<form action="enter_message" method="post">
<input type="text" name="message_text" encoding="form" />
<br />
<input type="submit" name="submit" />
</form>
</body>
</html>
::::::::::::::
apps/test/Root/main.hac
::::::::::::::
renderSkin('main');
::::::::::::::
apps/test/Global/main.skin
::::::::::::::
<html>
<head>
<title>Test app</title>
</head>
<body>
<h1>Demo app</h1>
<% response.message %>
<a href='enter_message'>Enter a new message</a>
</body>
</html>
-----------------
Thanks for any help you can give me.
--Tom
_______________________________________________
Helma-user mailing list
[email protected]
http://helma.org/mailman/listinfo/helma-user