tornadoweb / tornado

Tornado is a Python web framework and asynchronous networking library, originally developed at FriendFeed.
http://www.tornadoweb.org/
Apache License 2.0
21.75k stars 5.5k forks source link

demos\websocket When i posted, 404: Not Found #1515

Closed sevenguin closed 9 years ago

sevenguin commented 9 years ago

Like the title, When i open demos\websocket, and post some message, 404 is showed to me.The url is http://127.0.0.1:8888/a/message/new

bdarnell commented 9 years ago

Are you sure the right server is running on that port? Any messages about "cannot bind to port" in the console where the websocket demo is running? If you've got a conflict on port 8888, you can run the demo on another port with the --port flag.

bdarnell commented 9 years ago

/a/message/new is from demos/chat/, not from demos/websocket/. It looks like you've still got the non-websocket HTML loaded in your browser while you've switched the server to websockets.

samuelchen commented 8 years ago

I face the same issue. It's not demos/chat. It's demos/websocket in templates/index.html, you may found <form action="/a/message/new" method="post" id="messageform">

samuelchen commented 8 years ago

The problem caused by the JQuery $().live() in chat.js ( I used another JQuery CDN) New version of JQuery may not support live. When I changed it to $("#messageform").one("submit", ...), it works

bdarnell commented 8 years ago

@samuelchen I've filed a separate issue for that: #1790