Well, the loc:formaction does put the target page into the form's action the way you'd expect, but the submit button may be doing something else...
On submit, the form reloads. I'm not sure what is telling it to do that.
In my validate, I start with -
loc:invalid=''
p_web.SetValue('retry','')
loc:alert = ''
I don't know what else is telling it there is an error and to reload rather than move on and follow the form's action. - Bruce?
Here is how I got to work very easily. I listened to my son, Dave.
He shakes his head and says,'Pop, why don't you just use a redirect?'
Oy! So there it is ...
Let the form fail and reload, except on the reload, you set up a quick redirect to where you want them to go.
In my case it is - Your account is locked! please contact your administrator!
In my validation - ValidateUpdate after the form ends, I check the users table for some stuff.
If that fails, I set a session variable -
p_web.ssv('FailedCount',USR:failcount) !Sets a SSV to be read on the reload
loc:alert = 'This account is locked.'
loc:invalid = 'Failed Attempts'
EXIT
Then in the XHTML tab I added a routine called locked
gave it a condition if p_web.gsv('FailedCount')
and this code-
'Please wait while we log you in...<<br/><13,10>'&|
'<<META HTTP-EQUIV="Refresh" CONTENT="1; URL=LoginLocked"><13,10>'&|
''
Done! You could make the message hang for a second or two by increasing the number after Content, but sure enough it goes where you want it.