uajax - Universal Ajax Forms or how I created htmx killer

Updated: 10th May 2023
Tags: javascript html forms ajax

How to post to facebook page using api with plain php

Updated: 26th April 2023
Tags: php facebook

crop center and resize image using cwebp respecting aspect ratio (php)

Updated: 30th March 2023
Tags: php cwebp

bootstrap 5 hide existing modal using javascript

Updated: 30th March 2023
Tags: bootstrap5 javascript

chart.js show percentage in pie chart

Updated: 28th March 2023
Tags: javascript chart.js

Convert php array to javascript array

Updated: 28th March 2023
Tags: php javascript

[Solved] file_put_contents(/bootstrap/cache/packages.php): failed to open stream: Permission denied

Updated: 17th February 2023
Tags: laravel php ubuntu

mysql str_replace

Updated: 4th February 2023
Tags: mysql sql
UPDATE my_table SET column1 = REPLACE(column1, 'search string', 'replacement');

php echo (convert) date to RFC 3339

Updated: 3th February 2023
Tags: php
echo date(DATE_RFC3339);
//convert from other format
echo date(DATE_RFC3339, strtotime('2023-01-01 05:55:55'));

How to make dark scrollbar in custom dark theme

Updated: 30th January 2023
Tags: css

If you have toggle dark theme, you can make scrollbars and inputs also dark.

For example you have dark theme with following markup

<body data-theme="dark">

Add this css to make scrollbars and inputs dark

[data-theme=dark] {color-scheme: dark;}

How to shrink font-awesome to use only few icons

Updated: 29th January 2023
Tags: css fontawesome

Why jQuery is still needed

Updated: 20th January 2023
Tags: javascript jquery

How to change auto_increment mysql

Updated: 9th January 2023
Tags: sql mysql
ALTER TABLE my_table_name AUTO_INCREMENT = 777;

uajax - universal ajax forms

Updated: 28th December 2022
Tags: javascript

Always add html {overflow-y: scroll}, to prevent layout shift (CLS)

Updated: 25th December 2022
Tags: css html

How to remove bin logs and turn it off

Updated: 19th December 2022
Tags: mysql

How to free unused mysql space - OPTIMIZE tables

Updated: 12th December 2022
Tags: mysql

How to create aliases in windows 10

Updated: 12th December 2022
Tags: windows alias

How to create symlink folder in ubuntu

Updated: 12th December 2022
Tags: ubuntu nginx

For example we have our folder in /etc/nginx/sites-available/example.com And to make virtual symlink folder here /etc/nginx/sites-enabled we run this

sudo ln -s /etc/nginx/sites-available/example.com /etc/nginx/sites-enabled/

Three stages of using programming framework

Updated: 11th December 2022
Tags: framework thoughts

Three stages of using programming framework:

  1. fascination with features and quick problem-solving

  2. squeezing the maximum out of all configurations

  3. difficulty in expanding the framework to new requirements

In result, throwing framework away and creating thing by yourself.