BEAUBUS
67 FOLLOWERS
A Web Development Blog. Mostly covering articles about PHP, JavaScript, CSS, Sass, SQL, Unix shell, Laravel, Vue, Tailwind, PhpStorm, Vim.
BEAUBUS
4M ago
Ever found yourself in a situation where you needed to generate a PDF with fixed headers and footers on each page? Maybe you've been through countless forums and documentation pages, only to end up more confused. If this sounds familiar, you're in the right place! Here is a straightforward ..read more
BEAUBUS
1y ago
A lot of times, while working on a project without CSS frameworks, I found myself googling for alert boxes, which I can copy and paste without any setup. Every time I paste the code it requires some additional adjustments. So I made inline Error, Success, Info, and Warning forms with a close button and zero javascript. I use it myself and now ..read more
BEAUBUS
2y ago
How to convert inline SVG image into PNG in the browser? —The easiest way is to draw it on the canvas and use toDataUrl() function. The catch is browser support, especially mobile browsers and desktop Safari. When you try to use toDataUrl() function of canvas with SVG, it becomes «tainted» and blows up with ..read more
BEAUBUS
2y ago
Tailwind CSS is a modern utility-first CSS framework with great documentation. This guide will show you how to extend Tailwind with plugins, which you can write yourself. We are going to create plugin.js file and include it in tailwind.config.js configuration file. The purpose of the plugin is to just output ..read more
BEAUBUS
2y ago
Recently I made a single file upload component for Vue with drag'n'drop support. I made it suitable for my Vue2 and Vue3 projects and while publishing on NPM, I thought there would be a simple way to make it installable for both Vue2 and Vue3 users. But there was a number of catches ..read more
BEAUBUS
2y ago
Imagine, you loaded an SVG file from the database and displayed it on the page. How to convert it to PNG? How to make download links? Nowadays, with modern browsers (bye-bye IE, I would never miss you) and html canvas, this is pretty simple, even using ..read more
BEAUBUS
2y ago
Imagine you have multiple domains on your server and you want to add a simple counter to count views and visits. In this tutorial, I’m going to describe how to implement views and visits counter with PHP and Redis. It would be the most simple solution without bots detection, just visits and views ..read more
BEAUBUS
2y ago
Regular backups are important. This tutorial shows how to back up the MySQL database daily and keep only the latest. It requires you to be familiar (a bit) with mysqldump and ..read more
BEAUBUS
2y ago
Most Three.js Hello World programs are just rotating cubes. Here we going to rotate the real Hello World text. And we would do it in one HTML file. We include the Three.js library through CDN and font directly from GitHub. Everything would work without a server, just open a final HTML file in the ..read more
BEAUBUS
2y ago
Tailwind CSS is a modern utility-first CSS framework with great documentation. This guide will show you how to extend Tailwind with plugins, which you can write yourself. We are going to create plugin.js file and include it in tailwind.config.js configuration file. The purpose of the plugin is to just output ..read more