-
Notifications
You must be signed in to change notification settings - Fork 40
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
No CaptivePortal support? #26
Comments
The issue here seems to be no ability to do a catch-all route, like I've done before and like what MicroWebSrv2 has, so I added it myself with the following code:
and then in _find_handler
It's not a fantastic solution, so maybe something better can be added to support a "not found" fallback route? Cheers :) |
Hey! :) I remember I was able to make captive portal work using
|
So basically solution (apart from DNS part) is to just handle few URLs, like: # Add URLs
web.add_route('/generate_204', captive_portal)
web.add_route('/hotspot-detect.html', captive_portal)
web.add_route('/library/test/success.html', captive_portal) |
Ohai! Yeah, my issue with adding all of the "usual captive portal routes" for the different platforms is that I have no way of testing them other than Mac/iOS based ones, so I was wanting to just do the "catch-all" approach. Catch all works for me because for this part of the application I can always be assured all traffic is for the captive portal experience. I have to say though, I've been struggling to work out how to get TinyWeb routes working in my own classes (I'm fairly new to MP and Python in general) - but your |
🎉 |
Seems you're happy with solution, closing issue - feel free to reopen it :) |
I've tried everything, but I can't get TinyWeb to serve me a webpage when my DNS is setup for a CaptivePortal.
DNS is set as a wildcard for 192.168.4.1, and I can surf to that page, and see the website, but it doesn't auto load it on connection to the AP.
It works correctly with other web servers (MicroWebSrv2, Sockets server).
Is there something I am missing? Should this be working, or if not, can this be added?
Thanks,
Seon
The text was updated successfully, but these errors were encountered: