Hi i am trying to write a silverlight applicaiton on Facebook. I am using Visual Studio 2010. I have created a silverlight application and VS created a test page for it automaticly. I can acces and test my application on localhost (I have installed iis7 with default settings on win7x64 fresh install). I am publishing the test page to wwwroot and everything works on localhost. But when i try to access my application from Facebook i am getting this error:
"HTTP Error 405.0 - Method Not Allowed
The page you are looking for cannot be displayed because an invalid method (HTTP verb) is being used."
But if i create a ASP.NET application and publist it same way it works.
So what sould i do?
Best reagrds
Olcay Ertas
Have you tried spoofing your host? I do not know if it is the case anymore, but in the past, Facebook refused to interact with http://localhost/. By editing my hosts file, I was able to get Facebook to interact with my local environment without having to push to a publicly accessible server.
Just edit your hosts file, putting in something like my.localhost.com, restart your browsers, and put that domain in to your Facebook app. It could work... apologies if it doesn't.
Related
I got an error which seems to be one of the common issues. I read the whole bunch or articles, but nothing seems to be working.
I am developing a small app in Azure using VS 2017 .NET (not Core). The app requires Azure AD authentication. Everything was working fine until yesterday.
This is what's happening now:
The application compiles and runs on the local PC (Win 10) with no problems.
Local application is using Azure AD with no problem to log in and out.
I am deploying it to Azure from inside Visual Studio (as usual) - no problem
Application runs in Azure with no problem as long as NO login is required.
If I have to log in (click Log In or by accessing controller which requires authorization) I get the error:
Parser Error Message: Could not load type 'AzureTest.MvcApplication'.
So far I checked:
namespaces - OK
rebuild, restart - OK
I created a completely new application in Azure and in VS2017, totally fresh. Still the same behavior.
I tried going back to VS2015 and creating a new test
application both in VS and in Azure - still the same issue. Again, this happens only when I try to log in using Azure AD
Any suggestions?
Thanks in advance!
PS - one more comment: parsing error happens when Azure site redirects me to local https://localhost:44397/. If my local app is running, then I just open it fine. So I guess this is authentication error, rather then parsing?
Thanks!
I used to leverage the Microsoft.Owin.Security.OpenIdConnect middleware to integrate Azure AD authentication with my web application.
one more comment: parsing error happens when Azure site redirects me to local https://localhost:44397/. If my local app is running, then I just open it fine. So I guess this is authentication error, rather then parsing?
For your scenario, you need to make sure the authentication of your web application could work as expected in your local side. When deploy to Azure side, you need to change the RedirectUri in your web.config file and point to your azure web app domain. Moreover, here is the detailed tutorial about Integrate Azure AD into a web application using OpenID Connect.
You need to add the Azure based URL as a Reply URL in the Azure application registration, and make sure that your application uses that when authenticating to Azure AD.
If you create a standard ASP.NET MVC Application from the Visual Studio 2017 template, it will create a file called "Startup.Auth.cs" in the "App_Start" folder.
In the call to app.UseOpenIdConnectAuthentication add a RedirectUriproperty to the OpenIdConnectAuthenticationOptions.
Thanks for the replies!
I found the link here today:
Not sure why that box was unchecked in publishing profile, I did not change anything since I published it before. I don't even see it unless I go into settings.. Anyways, this solved the problem.
Thanks again!
I've made a C# ASP.NET Application using VS 2013. What I want to do is use it on my localhost using IIS.
How do I do it work? When it go to localhost, it just appears a black page.
I've created a new site on IIS Manager and ponted it to de fisical path of my application. Registered the ASP.NET on IIS...
I've tried whats in the How do you publish an ASP.net MVC application from Visual Studio 2013 to your local network? .
So, I don't need to use IIS, I could use other web server, like Apache...
I want to be able to open Chrome, go to localhost:8080/ for example and get my application, without having to open VS and run the project etc...
Also, if other people could access the application on my local network, it would be great. I just want to use my MVC web aplication like it was on the internet itself, like I can access google.com and use it, but I want to do so in my local network only.
If I try to access a simple HTML file, using IIS, it works perfectly. Now I want to use my C# MVC web application.
Is there a way to do this? Using IIS, Apache, whatever...
I'm trying to test my application against the OAuth Microsoft Account Login.
I have added the following to my hosts file
127.0.0.1 testdomain.co.uk
My application is running over https so when I run the app it runs as follows;
https://localhost:44308/home
Now when I hack the url to be
https://testdomain.co.uk:44308/home
I get the certificate warning (which is to be expected). However, when I click continue to site, i get a 400 Web Page cannot be found error?
Any ideas on what i am doing wrong here?
You need to tell your web server that it should handle the testdomain.co.uk for this project. Your web server (IIS Express) does not know it, as by default it is set to handle "localhost" host only. How to change that is described here: https://stackoverflow.com/a/32365556/3835864
Hello everyone.
I have implemented an ASP.NET web service that performs a query on a RavenDB database. I have then called this service by clicking on a button of a web page that is part of my web site and it is working just fine. I have generated a package from this web site. I have imported this package on IIS 8 located in another machine of the network I am connected to. On this other machine, when I launch the web site, is it working, but when I try to access the service by clicking on a button of a web page, I get the error displayed in the enclosed file. Is this error due to the fact that the web site is unable to locate the web service? If so, how can I fix it? If not, where does this error comes from?
Thanks in advance.
I have created a website using asp.net c# for my college library,i have completed it with all their requirements.I know setup files cannot be created for asp.net websites,so,now i need a way to at least create a link for the website,so that they can access the website from anywhere in the college systems and use it.I have tried deploying and publishing nothing is working.I need any other ideas.
Make sure that the web server you're deploying on is publicly (or at least locally within your college network) accessible. If it is, then accessing a particular website is just a matter of sharing its URL with others. You don't need a SETUP for it.
Note that what you see in a browser when you press F5 is most likely an instance of the built-in "ASP.NET Development Server" that is accessible only on the development machine. You need to deploy your site to an instance of IIS (or some other equivalent) to access it from other machines.
There are 2 steps that you need to perform.
Publish the website
Hosting
You can do it either in the IIS of local domain server to be accessible within the network
OR you can purchase a domain and host it on server to be accessible from anywhere.
You can see this on how to host application in IIS 7.
There are two types of deployment
Local
Global
Local Deployment: Download Cassini Web Server , Install it and Configure the WebApp or Website on that. It will give you the Network Url. Use that url to access it from anywhere in your local network.
Global Deployment: Go to Domain and Hosting Provider, purchase domain and link that domain to webspace and hosting that will Support .Net framework. Generally all windows based hosting now a days have IIS. Do not go for LINUX ,as you need MONO there which is generally not available. Upload you publish pages in the root of our virtual directory. In most of the hosts its httpdocs and some where have wwwroot, depending upon the control panels. Access that pages from the domain name.
this website provides all the details step by step!! its awesome it worked for me :)
http://www.programmerfish.com/how-to-deploy-asp-net-web-application-on-the-network-in-windows-7/