WebSockets are a fascinating technology, a TCP-based network protocol that allows for asynchronous bi-directional communication. The client starts a connection, sends a request and gets a response - just like HTTP. But much unlike HTTP this connection is kept alive! This has many advantages, like Faster responses (no re-establishing connections) Less trafic (no overhead
Wouldn't it be great if you could allow users to create screenshots of your website?! Apart from being a fun exercise this feature could come in handy when you're providing some kind of visual editor. After users customized their individual product, you could show them an image of what they created on checkout.
Having a script executed when a USB device is inserted can be quite helpful. I, for example, have an export script that syncs files to a flash drive without any interaction (except putting the drive in, of course). Here's how you do it: Adding The Rule In /etc/udev/rules.d/ we add a rules-file.
When working on my reverse engineering of 2048 for browsers I wanted it to be playable on mobile devices as well. Problem was, that while you could perfectly use your keyboard to control the tile movement on a desktop, this was not possible on smartphones! Digging through the web I found some partially working
After encrypting text in the previous post, here's how you get your plaintext back. The code Decoding After checking for a signature and saving it for later if there is one, we decode the Base64-encoded string back to raw. CryptoJS kindly does the actual decoding just after we reversed our
Maybe you followed my series on symmetric encryption with AES in PHP. You can check it out here if you're interested! What if I told you, that you don't even need a server to do that but might as well encrypt text using AES right in your browser? Sounds crazy? Well, you're in for
This post is part of a series about symmetric encryption with AES-256 in PHP. Table of Contents: Encrypting text Decrypting text Encrypting files Decrypting files In this last part of our series we're going to learn how to decrypt files we previously encrypted using our Crypto class. Check out the code: