Reputation: 2048
I am creating docs via Domino Access Service and I would like to add the HTTPPassword field.
This field normally is translated via the
@Password(HTTPPassword)
formula. How can I establish something via a HTTP post? Now the field is set as 'normal text'.
var newPersonObj = {Form: "Person", HTTPPassword: "lotusnotes"};
$.ajax({
url: '/tools/fakenames.nsf/api/data/documents',
type: 'POST',
data: JSON.stringify(newPersonObj),
dataType: 'xml',
accepts: {
xml: 'text/xml',
text: 'text/plain'
},
contentType: "application/json"
}).done(function(data, textStatus, jqXHR) {
var newPersonLocation = jqXHR.getResponseHeader("Location");
});
Upvotes: 1
Views: 109
Reputation: 2048
I found out I can include the &computewithform=true parameter in the URL so field translation is performed and the @password function is executed in the translation formula for the HTTPpassword field
Upvotes: 2
Reputation: 2018
I guess who want to get data submitted by a POST:
Set s = New NotesSession
Set doc = s.documentcontext
If doc.REQUEST_CONTENT(0)<>"" Then'it's a POST
Where REQUEST_CONTENT will contain all the data posted in url encoded format (var1=val1&var2=val2...)
If I misunderstood, sorry, and I will erase/edit this response
Upvotes: 0