Connect 4 in JavaScript and HTML

In this post I will show you how to program the Connect 4 game by using JavaScript with HTML and Vue, with Bootstrap styles. It is the Connect 4 game but web version with a player versus player option, as well as player versus CPU that uses a small artificial intelligence. Throughout the post I will show you how the game works, what technologies I have used, styles, etc. I will also show you how to download the source code, as the game is totally free and open source. Finally I will leave you a demo to play connect 4 online. ...

August 24, 2020 · 17 min · 3559 words · Parzibyte

Java: binary to text translator

In this post about Java I am going to teach you how to convert text to binary, and binary to text. That is, make a type of text - binary translator in Java to be able to convert between both formats. Another way to call this is to say “Binary to English translator” for example. For example, convert 1110000 1100001 1110010 1111010 1101001 1100010 1111001 1110100 1100101 101110 1101101 1100101 to “parzibyte.me” and vice versa. All this programmed in Java with manual methods and custom logic. ...

August 21, 2020 · 6 min · 1164 words · Parzibyte

How to print QR codes on Thermal printer

Summary: In this post I will show you how to print readable QR codes on a thermal printer (also called ticket printer, pos printer, etc.) using JavaScript and a plugin. If you have followed my posts, you will know that a long time ago I developed a plugin and I have added new features, until today we print QR codes on a thermal printer. Some time ago I showed you how to print a ticket /receipt directly from browser, today we will use it to print a QR code. ...

November 25, 2019 · 2 min · 336 words · Parzibyte

A plugin for printing in thermal printers directly from browser

In this post I will introduce to you a plugin for printing tickets, receipts or invoices on a thermal printer using client-side JavaScript even if your web page or application is on a cloud server. This plugin allows you to print directly from browsers, without dialogs and without browsers compatibility issues because you only have to send a HTTP request to print silently and in the background. ...

October 14, 2019 · 3 min · 547 words · Parzibyte

How to share a printer on Windows

In this post I will show you how to share a printer on Windows 10, directly from the control panel. ...

October 14, 2019 · 1 min · 97 words · Parzibyte

PHP & MySQL tutorial using PDO

Although there are millions of tutorials about MySQL and PHP, I decided to make mine but in a very very simple way. Before you start, you must have a basic knowledge in MySQL. It is worth mentioning that we will not see good practices of databases, relationships, etc. We will use the tables as they are, without looking at normalization, or things like that. Note: this tutorial uses PDO, but remember that we can also use mysqli functions. Personally I recommend PDO, because it is object oriented. However, I hope to write a tutorial about mysqli in the future. ...

October 14, 2019 · 8 min · 1661 words · Parzibyte

Print ticket in thermal printer directly from browser

In this post I will show you how to print a receipt in a thermal printer directly from web browser, without user interaction and confirm dialogs, by using a free plugin. ...

October 14, 2019 · 3 min · 516 words · Parzibyte

Print receipt in thermal printer using JavaScript, CSS & HTML

In this post I will show you how to print a ticket or receipt by using JavaScript (client side) and a thermal printer. At the end we will have a great ticket that looks like this: Obviously you can change the font family, size, logo and so on. And remember: we will be using only pure CSS, HTML & JavaScript, no frameworks; though you can use any framework to render the content before printing. You can see the demo here, and the full code on my GitHub. ...

October 10, 2019 · 3 min · 596 words · Parzibyte

Custom alert dialog in Android

Dialog and AlertDialog with custom layout on Android In this post I will show you how to create custom dialog on Android using a layout created by us, that is, create a custom alert by adding elements such as EditText, Button, etc. Custom alerts on Android serve to display an alert that is not a confirmation alert, since we can define a custom layout. To achieve this we will use the Dialog and AlertDialog.Builder classes. ...

August 28, 2019 · 4 min · 812 words · Parzibyte

How to redirect in Spring Boot

Redirect in the Spring Boot framework In this post I will show you how to redirect or direct the user to another URL within the method of a controller in the Spring Boot framework. Redirecting to another URL in Spring Boot is very useful when the user does a certain action and we must return it to the main page. ...

August 26, 2019 · 1 min · 212 words · Parzibyte