2

Have changed computer to run my project and website on, and now it doesn't work at all.

When I go to http://localhost:8080/signalr/hubs I get "ERR_CONNECTION_REFUSED"

In my Self-Hosted aplikation:

string url = "http://*:8080";
using (WebApp.Start(url))
 {
     writeStatus("Server running on " + url);
 }

And on my website:

<script src="http://localhost:8080/signalr/hubs"></script>

What have i missed?

Dexception
  • 163
  • 2
  • 10
  • 1
    Have you seen this: http://stackoverflow.com/questions/21849511/how-to-prevent-signalr-errors-from-stopping-further-execution-of-javascript ? – Pawel Jul 09 '15 at 00:09
  • Yes i have now. Didn't really help me so much tho. Looking in Chrome devtools it shows that i get the "ERR_CONNECTION_REFUSED" on the line with `` – Dexception Jul 09 '15 at 08:35
  • I tried now to download a sample project from here http://www.asp.net/signalr/overview/deployment/tutorial-signalr-self-host , and it works with that one using the same adress and port. Could it be that im using wpf and they used console applikation? – Dexception Jul 09 '15 at 21:38
  • Could it be that you have some kind of ad blocker like U Block or something that blocks it? Can you try with another browser that doesn't have any plugins to see if you still get the same error? – Ed C Feb 17 '17 at 08:51

1 Answers1

0

Try this-->CorsOptions.AllowAll;

        app.UseCors(CorsOptions.AllowAll);
        var hubConfiguration = new HubConfiguration() ;
        hubConfiguration.EnableDetailedErrors = true;

        app.MapSignalR(hubConfiguration); 
Ufuk Aydın
  • 158
  • 3