Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Forwarding Webserver with websockets #1416

Open
MeisterQ opened this issue Jun 11, 2024 · 2 comments
Open

Forwarding Webserver with websockets #1416

MeisterQ opened this issue Jun 11, 2024 · 2 comments

Comments

@MeisterQ
Copy link

MeisterQ commented Jun 11, 2024

Hello,

i need to forward my Webserver with websocket connection on my router.

Im using a Fritzbox 7590 AX.

If i forward port 80 from example ESP_AsyncFSBrowser.ino where websockets is defined with "/ws", the websocket connection is not being etablished.

The webpage is shown, but webserver data is not transfered via websockets.

This message is shown in debug window of the browser.
image

Any idea how to fix it? Is it maybe library related? I need a fix for this problem.

Thanks in advance.

Please do not discuss about how to expose it otherwise, because this fritzbox is just a sub-router inside my network (At work) and is not exposed to the internet.

@oldst49
Copy link

oldst49 commented Jul 25, 2024

Socket = new WebSocket('ws://' + document.location.host + '/ws'
Try it.

@MeisterQ
Copy link
Author

Socket = new WebSocket('ws://' + document.location.host + '/ws' Try it.

You're my hero. Its working. Thank you!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants