how does pastie or any other site remember browser info - webbrowser-control

I am trying to make a simple experimental app. I'd like for it to behave like pastie.
On pasite you can paste code and it will remember your browser.
So if you paste the url (that pastie provides) in the same browser then you'll be able to edit the page. Everyone else will not see the edit link. Basically there is no registration or logging in.
How is this done?

Using HTTP cookies.

Related

Docusign RESTful URL is not stable

For some unknown reason, when I used the same URL that had worked yesterday, it won't work again today. Still not sure what is the reason.
The URL I used yesterday was (I did see tab content yesterday):
curl -silent https://www.docusign.net/restapi/v2/accounts/0000000/envelopes/aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa/recipients/tabs?include_tabs=true
Today, the above URL will not work any more (I won't be able to see tab content) unless I change the URL to:
curl -silent https://www.docusign.net/restapi/v2/accounts/0000000/envelopes/aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa/recipients/1/tabs
Strange. Not sure what is changed at server.
I have tried a different user account to login, then the first URL started to work. It could be somewhere there is a setting to control restful API behavior for each user account. But I am not aware where it is.

Google AppEngine API Explorer redirects and lists no URLs

I'm having an unending issue trying to use the AppEngine API explorer with the stupidly simple helloworld example.
When trying to navigate to the url to explore the API my Chrome browser redirects to HTTPS from the default HTTP and no API's are listed. I have gone through every possible fix I can find (Like this, and all of these) and none are working reliably.
What's the most infuriating is I have gotten the API listed TWICE but now no longer displays with any of the methods below.
The setup I had when it worked the first time:
Chrome launched with "C:\Program Files (x86)\Google\Chrome\Application\Chrome.exe" --unsafely-treat-insecure-origin-as-secure=http://localhost:8080 (As per the tutorial)
The url being: (http://)apis-explorer.appspot.com/apis-explorer/?base=http://localhost:8080/_ah/api&root=http://localhost:8080/_ah/api#p/
The second time it worked was using also using the above URL but lasted only a second before being redirected to HTTPS and not listing anything.
Some specifics:
Windows 10 OS.
Every time the page loads I get the "The API you are exploring is hosted over HTTP, which can cause problems. Learn how to use Explorer with a local HTTP API." message, even the times the API displayed correctly.
Every time I now load any of the API Explorer URLs I get redirected to HTTPS, and nothing is listed. Also the URL is escaped (%3A instead of ':'). Not sure if it's important but the first time it worked the URL was HTTP and NOT escaped.
I have tried the shield in the search bar and enabling Load unsafe scripts ( from here).
Tried launching Chrome as usual and with the flags --unsafely-treat-insecure-origin-as-secure=http://localhost:8080 and/or --allow-running-insecure-content (from this answer).
Tried http://localhost:8080/_ah/api/explorer
Tried http://apis-explorer.appspot.com/apis-explorer/?base=http://localhost:8080/_ah/api#p/
http://localhost:8080/_ah/admin works correctly and shows the Admin console every time.
Since the API's being listed once I haven't touched the project code, but restarted the server, Chrome, and tried different URLs on more occasions than I care to count.
I also tried accessing the API URL directly as explained in this answer but cannot find the correct URL to access the helloworld /sayHi endpoint. Maybe someone can help me work out what I need to prefix it with as all of the variations I try give me a 404.
Any help would be a very very appreciated.

Url scheme in Facebook feed dialog

So I finally got a link in my facebook post using the properties parameters. I thought I could put my url scheme in there. But unfortunately it says it isn't a valid url, which makes sense. So I searched again for another solution. But everyone seems to be talking about fb:// and not their own app url scheme.
So I created this thread, hope somebody can help me.
Try using bit.ly (or some other URL shortener).
The last time I tried, bit.ly accepted any URI schema and just did a redirect. I've successfully used this in the past to work around inputs that expected either an HTTP or HTTPS schema.
Additionally, similar logic could be done on your own server if you prefer. Simply share a link to your own server on Facebook, and have your server side script do a 301 to whatever App specific URI you have.

Cookies are not working in QWebView

When I load an Url using the load method, like this:
load(QUrl("http://www.foo.com"));
Cookies work correctly with no problems. However, when I load the content using the setHtml method, like this:
setHtml(htmlCode, QUrl("http://www.foo.com));
The website indicates that cookies aren’t enabled in my browser. I wonder if this is a known issue, and whether there’s a way to have cookies working for the setHtml method.
Thanks in advance.
Cookies are from HTTP protocol, not part of HTML. You need a http server embedded, Take a look at this project

http://dev.twitter.com/ redirects to http://twitter.com/

I am trying to access my Twitter API but the call is failing due to the redirect. Does anybody know why this is happening and or how I can fix it? Yes, I am signed in.
Are you using the "Use HTTPS" on Chrome, or a similar extension?
For me, it redirects http://dev.twitter.com to https://dev.twitter.com, which in turn redirects to https://twitter.com
Ideally, the extension would offer more control in how it matches domains. Meanwhile, a quick workaround is to open an incognito window, for which extensions are disabled, and view dev.twitter.com there.