Hello,
I'm attempting to add some functionality to my portlet that would allow
a person to provide an email address via form. I've had it working on
and off for months, but it's off again - and I'm not sure my approach is
sound (since it keeps breaking).
 
What I'm doing is using a Velocity Portlet Action called doSendemail
which opens page via java.net.URLConnection (capturing the active
JSESSIONID to spoof the current session), saves the contents of the page
in a variable, and emails the page to the specified email address.
Everything works consistently except for the page that loads via
connection string. I've tried several variations; this is the latest one
that is not working:
 
URL url = new
URL("http://localhost/housing-portal/portal/media-type/html/role/user/xx
x/page/default.psml/" + rundata.getParameters().getString("jspeid") +
"?action=controls.Print&requestID=" +
rundata.getParameters().getString("requestID"));
 
I've tweaked this URL a few times, to make it work - but then I make
minor changes to my PSML or other settings and it breaks. I feel like
I'm going about this the wrong way. 
 
Any ideas of a better direction?
Jason
            

Reply via email to