direct action URL without a session
direct action URL without a session
Hello there,
the subject says it all — is there a decent way to construct a direct action URL from a code which has no session (and thus no context)? Note I need a full URL, not a relative one (it is to be used in diverse ways like “sent to client by an e-mail” etc.)
At the moment, I use
Application app=Application.application()
String url=app.cgiAdaptorURL+'/'+app.name+'/'+app.directActionRequestHandlerKey+'/'+directActionName+'?'+directActionAttributeName+'='+directActionAttributeValue
which sort of works, but is not too flexible (e.g., it stops working with direct access, where it lacks the port), it is very slightly incorrect (does not contain ".woa"; seems harmless, but still weird), and besides, is pretty ugly code (and would become far uglier with more attributes than one). Is there a better way?
Thanks,
OC
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden