edbrowse-dev - development list for edbrowse
 help / color / mirror / Atom feed
From: Kevin Carhart <kevin@carhart.net>
To: Adam Thompson <arthompson1990@gmail.com>
Cc: Karl Dahlke <eklhad@comcast.net>, Edbrowse-dev@lists.the-brannons.com
Subject: [Edbrowse-dev] response headers and body?
Date: Sun, 27 Dec 2015 01:18:12 -0800 (PST)	[thread overview]
Message-ID: <alpine.LRH.2.03.1512270053470.12373@carhart.net> (raw)
In-Reply-To: <20151227075410.GA4059@hob.adamthompson.me.uk>



>> Oh I don't know, your submissions are always helpful.
> Agreed.

Great.  Thank you, in that case I'm working on this now
but I noticed that
when prepareForBrowse populates the string 'javatext' after
a successful '200 OK' response, this is just the page body.
Is there a way to return the entire 'raw' response with
headers on the beginning?  I think the idiom is that the
xhr object in JS will have
blah.responseHeaders
blah.responseText
and maybe
blah.responseXML
etc

And some calling site's code might then switch on the
response header values, or grab the Set-Cookie:, or something.

I'll remove my hardcoded test for hcode=='200' and assuming
that both headers & body can be returned to JS, just deal
with carving it up there.

Adam said,
> How about a toggle? Karl could that work?
> Like an xhr command to toggle whether xhr actually made connections or not.

Sounds like a good idea- this would be a boolean similar to
other configurables, right?  So if I carry on with this routine
I'm doing, then later it could be wrapped in:
if (xhr)
{
}

Is that OK?

thanks
Kevin

  reply	other threads:[~2015-12-27  9:17 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-12-22 23:13 [Edbrowse-dev] Rebundle Karl Dahlke
2015-12-23 23:17 ` Kevin Carhart
2015-12-24  0:01   ` Kevin Carhart
2015-12-24  0:04     ` Kevin Carhart
2015-12-24  0:17       ` Karl Dahlke
2015-12-24  0:46         ` Kevin Carhart
2015-12-25 15:10       ` Karl Dahlke
2015-12-26  8:44         ` [Edbrowse-dev] Rebundle / One program # processes Kevin Carhart
2015-12-26 15:56           ` Karl Dahlke
2015-12-27  7:54             ` Adam Thompson
2015-12-27  9:18               ` Kevin Carhart [this message]
2015-12-27 13:38                 ` [Edbrowse-dev] response headers and body? Karl Dahlke
2015-12-27 21:03                   ` Kevin Carhart

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=alpine.LRH.2.03.1512270053470.12373@carhart.net \
    --to=kevin@carhart.net \
    --cc=Edbrowse-dev@lists.the-brannons.com \
    --cc=arthompson1990@gmail.com \
    --cc=eklhad@comcast.net \
    /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;
as well as URLs for NNTP newsgroup(s).