Login  Register

RE: RE: RE: Re: Can anyone tell me where this file will be whats the name of this

Posted by smaran on Mar 09, 2011; 5:09am
URL: https://discuss.orbeon.com/Can-anyone-tell-me-where-this-file-will-be-whats-the-name-of-this-tp3341219p3342794.html

Hi
 You mean to say I have following url while creating new form http://localhost:8080/orbeon-PE/fr/orbeon/builder/new
so you suggest me to change url as below?
http://localhost:8080/orbeon-PE/fr/orbeon/builder/new?username=smaran
so that I can acess in crud.xpl as
<username><xsl:value-of select="$request/ username "/></username>


Please correct me if I am wrong attaching my crud.xpl for reference
Regards,
Smaran

-----Original Message-----
From: Tom Grahame [mailto:[hidden email]]
Sent: Tuesday, March 08, 2011 8:35 PM
To: [hidden email]
Subject: [ops-users] RE: RE: Re: Can anyone tell me where this file will be whats the name of this

Smaran,

There are two ways that I can think of to add attributes to that XML infoset; changing the HTTP request that the request generator is describing and transforming the infoset using XSLT. I think the first way is the one you might be interested in.

Depending upon how crud.xpl is activated in page-flow, you could add URL parameters to a GET request and they would appear in the request infoset. So if your page flow was like this (not tested):



And you made this GET request

http://locahost:8080/orbeon/crud?username=tom&password=insecure

This would appear as part of your request infoset (the rest of the infoset excluded for brevity):



username
tom


password
insecure




Similarly, if you change any other parts of the HTTP request the crud.xpl receives, like the port, remote address, or anything else, those values will be changed in the request infoset.

I recommend you add a debug attribute to your request generator and then execute crud.xpl with different HTTP requests, whilst watching the output of orbeon.log to see how the XML changes.





/request






Now if what you're actually trying to achieve is an authentication mechanism, I have had success by reading session parameters in XPL using the scope-generator processor. In my application a Struts action handles the authentication against LDAP and writes a parameter isValid into the session if the authentication is successful. Any pipelines that need to be authenticated are able to read from the session and check for that value:





isValid
session
application






Hope that helps,

Tom

--
View this message in context: http://orbeon-forms-ops-users.24843.n4.nabble.com/Can-anyone-tell-me-where-this-file-will-be-whats-the-name-of-this-tp3341219p3341548.html
Sent from the Orbeon Forms (ops-users) mailing list archive at Nabble.com.

Please do not print this email unless it is absolutely necessary.

The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addressee(s) and may contain proprietary, confidential or privileged information. If you are not the intended recipient, you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately and destroy all copies of this message and any attachments.

WARNING: Computer viruses can be transmitted via email. The recipient should check this email and any attachments for the presence of viruses. The company accepts no liability for any damage caused by any virus transmitted by this email.

www.wipro.com


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws

crud.xpl (37K) Download Attachment