I try and call this endpoint with an access token from auth2:
https://gdata.youtube.com/feeds/api/users/default?access_token={mytoken}&alt=json
and when I use it for a user with a channel on youtube it works fine. though, when I try to use it for an "unlinked account" user (no channel on youtube yet) it returns me this html response
<HTML>
<HEAD>
<TITLE>User authentication required.</TITLE>
</HEAD>
<BODY BGCOLOR="#FFFFFF" TEXT="#000000">
<H1>User authentication required.</H1>
<H2>Error 401</H2>
</BODY>
From what I've searched I saw that I should use v2.1 instead of v2.0 and so I tried to add header to the request "GData-Version=2.1", though nothing seem to change in the response. Still same error. Also, tried to add querystring "&v=2.1" and still nothing.
Any help would be appreciated. Thanks.
Ok the v=2.1 did work at the end.
Related
Hi I am receiving the following error (on all my sites) when the site attempts to embed a twitter account timeline. I looked at the status page https://api.twitterstat.us/ and it makes no mention of any problems with twitter...
https://cdn.syndication.twimg.com/timeline/profile?callback=__twttr.callbacks.tl_i0_profile_ingentaconnect_old&dnt=false&domain=ic.ox-dev-01.ingenta.com%3A9151&lang=en&screen_name=ingentaconnect&suppress_response_codes=true&t=1829998&tz=GMT%2B0000&with_replies=false net::ERR_ABORTED 404
fetch # widgets.js:8
Here is the embed code:
<a class="twitter-timeline" data-height="340" href="https://twitter.com/ingentaconnect?ref_src=twsrc%5Etfw">Tweets by ingentaconnect</a>
<script async src="https://platform.twitter.com/widgets.js" charset="utf-8"></script>
Note I'm based in UK if it is relevant.
This worked for me perfectly.
A workaround is to get https://platform.twitter.com/widgets.js; in its code, change https://cdn.syndication.twimg.com to https://syndication.twimg.com, store within your website and when embedding Twitter timeline, use your modified version instead of https://platform.twitter.com/widgets.js.
Here is the link on twitter where the discussion was done:
https://twittercommunity.com/t/embedded-timeline-does-not-show/168085/10
I'm trying to create a custom login page that is hosted in my MVC Web App however the request is being redirected to my default error page with the message
"server_error".
What can I do to find more information about this error?
My custom login page:
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title></title>
</head>
<body>
<h1>This is my custom login page.</h1>
<div id="api"></div>
</body>
</html>
Other Notes:
My web app is based off of the Azure AD B2C: Call an ASP.NET Web API from an ASP.NET Web App.
I'm following the article Azure Active Directory B2C: Customize the Azure AD B2C user interface (UI)
I've enabled CORS Enabling Cross-Origin Requests (CORS)
Update:
The problem was that I didn't enable CORS correctly in my web app. The documentation I was reading was for .NET Core vs .NET Framework I was using.
I added this to my view.
HttpContext.Current.Response.Headers.Add("Access-Control-Allow-Origin", "https://login.microsoftonline.com");
P.S. #spottedmahn recommendation for preserving the log in the Chrome console clearly showed why the error was occurring.
Assuming you're running locally, Enable SSL in IIS Express. The problem could be mixed content: HTTP & HTTPS.
Also, in your browser, enable preserve log; this will provide more insight into your error(s).
You could enable application insights to record the error.
Here is some documentation on how to collect logs.
I want to redirect url, general code is as follows:
<html>
<head>
<meta name="referrer" content="always">
<script>
document.location.replace(url);
</script>
</head>
Other browsers can send referer, why the Safari is not?
How to send referer in the Safari browser on the ios?
Can you help me please.
The transition to many websites to https websites instead of http websites has caused a loss of referrer tags; this occurs because when transferring from an http link into a https link, the referrer information is dropped.
So if you're on an http page, and link off to an https page, no referrer header is available when you land there.
One solution to this is to change your pages to https; then your visitors will be going from https to https, and the referrer information will come along as expected.
Please try to add this to your
This should fix it for desktop Safari. It may not fix it for ios safari. You may want to use content of origin or place it as a hidden field in the page via JavaScript.
A good explanation: http://smerity.com/articles/2013/where_did_all_the_http_referrers_go.html
I You using frame(in my case) then use document.location.href = url; instead of replace(url)
We have an app that is integrated with Google Apps domains, which allows domain admins to provision users in their Google Apps Domain in our web app on a nightly basis.
Previously I noticed that in cases where the admin revoked access to our app in the cpanel for the domain we would get a HTTP 403 or 401 sometimes, I kinda found this out via some manual testing on my own personal test domain. However, last week we started seeing HTTP 400s even though the request was correctly formed (GET request url and params).
I have two questions
Anyone know where in the Provisioning API docs is there info on the various possible HTTP response codes that I can expect.
Anyone else see the surge in HTTP 400s lately, due to some undocumented API update ?
UPDATE: The response body for the call is
<HTML> <HEAD> <TITLE>Bad Request</TITLE> </HEAD> <BODY BGCOLOR=\"#FFFFFF\" TEXT=\"#000000\"> <H1>Bad Request</H1> <H2>Error 400</H2> </BODY> </HTML>
UPDATE2: This is the request URL I'm using
"https://apps-apis.google.com/a/feeds/#{domain}/user/2.0?alt=json"
I have two problems: (IOS + XCode + PhoneGap)
After doing Hackbooks Facebook login I load an iframe which loads fine. When I click a like button from my app, it takes me to a Facebook login page. How come it does that when I'm already connected?
When the login page of Facebook comes up and I sign in, I get a blank page and I get a console error saying: "Error: executing module function 'setInfo' in module 'cordova/plugin/ios/device'. Have you included the iOS version of the cordova-1.9.0.js file?" I have the JS file in my WWW folder.
Can someone please give me a hand?
Maybe try this:
http://docs.phonegap.com/en/1.9.0/guide_upgrading_ios_index.md.html
I don't know much about Facebook logging so I can't help much with Question 1, but for Question 2 it sounds like you are getting redirected after login to a page that does not include cordova-1.9.0.js.
Your index.html must be including the js file for you app to be doing anything, but apparently you are getting redirected back to a different page, so make sure that page also has a script tag for cordova-1.9.0.js.
You need this:
<head>
<script type="text/javascript" charset="utf-8" src="cordova-1.9.0.js">
</script>
</head>