From: Peter.Gregory@cis.strath.ac.uk
To: caml-list@yquem.inria.fr
Subject: Basic Ocamlnet Question
Date: Tue, 14 Aug 2007 18:29:59 +0100 (BST) [thread overview]
Message-ID: <1628.84.13.116.50.1187112599.squirrel@webmail.cis.strath.ac.uk> (raw)
In-Reply-To:
Hi,
I've just started messing about with ocamlnet, and have instantly run
into a problem. I was trying to write some code that interfaced with the
backpack API (http://developer.37signals.com/backpack/). I tried
tweaking one of the examples just to get a page listing, and wrote the
following:
open Http_client.Convenience;;
let get_and_print url =
let s = http_post url [("","<request> <token>mytoken</token>
</request>")] in
print_string s;
flush stdout
;;
let () = get_and_print "http://pg.backpackit.com/ws/pages/all";;
However, this doesn't work, as the header for the request should be
"Content-Type: application/xml". How do I set the header for my request
in ocamlnet?
Thanks,
Peter.
next reply other threads:[~2007-08-14 17:30 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-14 17:29 Peter.Gregory [this message]
2007-08-14 17:39 ` [Caml-list] " Oliver Bandel
2007-08-14 17:46 ` Gerd Stolpmann
2007-08-14 19:37 ` Peter.Gregory
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1628.84.13.116.50.1187112599.squirrel@webmail.cis.strath.ac.uk \
--to=peter.gregory@cis.strath.ac.uk \
--cc=caml-list@yquem.inria.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox