To achieve this, you would need to request the next page
with XMLHttpRequest, and then parse the output.
Basically, you could check for word "Exception" or something,
or maybe alter your controllers so, that in the case of an exception,
they would render some obvious XML for the javascript to parse out.
If there's nothing to signify there was an error, depending on
how you've implemented it, you could simply replace the current HTML
with the one you got with XHR.
Hope that gives some ideas on how to proceed =)
On Fri, 01 Aug 2008 20:45:23 +0300, Samuel Verdier
<[EMAIL PROTECTED]> wrote:
Hi,
I would like display an exception in javascript.
If an exception is lift in the controller, i want stay in the current
page
and display the exception in javascript alert.
How can I do that ?
Samuel verdier – Directeur technique
[EMAIL PROTECTED]
www.pyxis.org
150, allée du Pays d’Oc, 34080 Montpellier - Tél. 04 67 10 77 88 -
Fax
04 67 10 77 87
41, rue Meslay, 75003 Paris - Tél. 01 42 85 55 04 - Fax 01 42 85 56
30
--
Jani Hartikainen
http://codeutopia.net/