4 ms·
You could do this with no CSS, only html.
by woah 8y ago
You could do this with no CSS, only html.
- chapium 8y agoCreate a demo then.
- Romanulus 8y agoNo, you.
- miguelmota 8y agoSkeptical because there needs to be some dynamic component to it which is what the CSS pseudo-selectors are achieving. Would love to see a working demo.
- driverdan 8y agoYou could do it with iframed buttons. Clicking a letter button posts to the server, an image is sent back in the forever loading page.
- lawl 8y agoYou don't need letter buttons. You can have a regular text box in an iframe and submit the form with the text. I actually remember websites doing exactly that years ago. Some would display the chat like here, by never closing the connection, as described in the repo. And another trick was to just send a refresh header (or use a meta tag) to automatically reload the iframe displaying the chat every $x seconds. The latter one was iirc more prominent because you could do it on any web host with PHP and MySQL as it doesn't require any long living processes.
- nwellnhof 8y agoThat's exactly how I implemented a web chat around 2002. IIRC, Internet Explorer didn't update the iframe with the chat messages reliably, so I had to fall back to reloading. The whole thing was rather inefficient, simply polling a database for new messages every second, but it worked fine for about 10-20 users.
- nhooyr 8y agomm, couldn't it just be a button that sends a form?
- qu4z-2 8y agoI hacked up an existing (shitty) webchat client I had around to do this: https://github.com/Qu4Z/chattr-nojs https://github.com/Qu4Z/chattr-nojs It still uses CSS so as not to be ugly, colour-code messages by user, and to position the "Enter message" box below the chat history, but I hope it gets the basic idea across. It should continue to work if you disable styling.