Now, I'm sure you have already figured out a way of doing it, but here is my take on it: (using prototype.js)
The trick is the "EditDocument&Seq=1&__Click=0" part...this will trick Domino into thinking you are submitting a normally edited document. You must of course have an existing form, and the field names must match, but you knew that;)
..I know it's a bit of a hack, btw...
Oh, and I didn't test this piece of code, but I have used this method before.
var dbUrl = new String(location.href.slice(0, location.href.indexOf('.nsf')+4)); //url to database
function postMe(docUNID) {
var url = dbUrl +'/0/'+docUNID+'/';
var pars = 'EditDocument&Seq=1&__Click=0&'+serialize(myForm);
Now, I'm sure you have already figured out a way of doing it, but here is my take on it: (using prototype.js)
The trick is the "EditDocument&Seq=1&__Click=0" part...this will trick Domino into thinking you are submitting a normally edited document. You must of course have an existing form, and the field names must match, but you knew that;)
..I know it's a bit of a hack, btw...
Oh, and I didn't test this piece of code, but I have used this method before.
var dbUrl = new String(location.href.slice(0, location.href.indexOf('.nsf')+4)); //url to database
function postMe(docUNID) {
var url = dbUrl +'/0/'+docUNID+'/';
var pars = 'EditDocument&Seq=1&__Click=0&'+serialize(myForm);
var myAjax = new Ajax.Request( url,
{ method: 'post',
parameters: pars,
onComplete: showResponse });
}
function showResponse(originalRequest)
{
//put returned XML in the textarea
alert(originalRequest.responseText);
}