Avatar
AhnizTech Portal Full Stack Developer
🏠 Home

📂 Blogs List | All Posts

Total articles: 36 | Latest ID: 36
Blog N° 36
Title: RHEL Nodejs PostgreSQL PgAdmin4
Content:
[labhak0@labvmrhel01 ~]$ sudo -i\r\n[sudo] password for labhak0: \r\n[root@labvmrhel01 ~]# hostnamectl\r\n Static hostname: labvmrhel01\r\n Icon name: computer-vm\r\n Chassis: vm 🖮\r\n Machine ID: f59ee43d0da146e8bf3b056e54e822b5\r\n Boot ID: 1906ef7f3dd04c35b210992f81847553\r\n Virtualization: vmware\r\nOperating System: Red Hat Enterprise Linux 9.8 (Plow) \r\n CPE OS Name: cpe:/o:redhat:enterprise_linux:9::baseos\r\n Kernel: Linux 5.14.0-687.42.1.el9_8.x86_64\r\n Architecture: x86-64\r\n Hardware Vendor: VMware, Inc.\r\n Hardware Model: VMware20,1\r\nFirmware Version: VMW201.00V.21805430.B64.2305221830\r\n[root@labvmrhel01 ~]# php -v\r\nbash: php: command not found...\r\nInstall package \'php-cli\' to provide command \'php\'? [N/y] N\r\n\r\n\r\n[root@labvmrhel01 ~]# psql --version\r\nbash: psql: command not found...\r\nInstall package \'postgresql\' to provide command \'psql\'? [N/y] n\r\n\r\n\r\n[root@labvmrhel01 ~]# dnf install -y postgresql postgresql-server\r\nUpdating Subscription Management repositories.\r\nLast metadata expiration check: 1:12:33 ago on Wed 26 Aug 2026 01:54:58 PM CET.\r\nDependencies resolved.\r\n=========================================================================================\r\n Package Arch Version Repository Size\r\n=========================================================================================\r\nInstalling:\r\n postgresql x86_64 13.23-5.el9_8 rhel-9-for-x86_64-appstream-rpms 1.6 M\r\n postgresql-server x86_64 13.23-5.el9_8 rhel-9-for-x86_64-appstream-rpms 5.8 M\r\nInstalling dependencies:\r\n postgresql-private-libs x86_64 13.23-5.el9_8 rhel-9-for-x86_64-appstream-rpms 145 k\r\n\r\nTransaction Summary\r\n=========================================================================================\r\nInstall 3 Packages\r\n\r\nTotal download size: 7.6 M\r\nInstalled size: 29 M\r\nDownloading Packages:\r\n(1/3): postgresql-private-libs-13.23-5.el9_8.x86_64.rpm 160 kB/s | 145 kB 00:00 \r\n(2/3): postgresql-13.23-5.el9_8.x86_64.rpm 404 kB/s | 1.6 MB 00:04 \r\n(3/3): postgresql-server-13.23-5.el9_8.x86_64.rpm 646 kB/s | 5.8 MB 00:09 \r\n-----------------------------------------------------------------------------------------\r\nTotal 838 kB/s | 7.6 MB 00:09 \r\nRunning transaction check\r\nTransaction check succeeded.\r\nRunning transaction test\r\nTransaction test succeeded.\r\nRunning transaction\r\n Preparing : 1/1 \r\n Installing : postgresql-private-libs-13.23-5.el9_8.x86_64 1/3 \r\n Installing : postgresql-13.23-5.el9_8.x86_64 2/3 \r\n Running scriptlet: postgresql-server-13.23-5.el9_8.x86_64 3/3 \r\n Installing : postgresql-server-13.23-5.el9_8.x86_64 3/3 \r\n Running scriptlet: postgresql-server-13.23-5.el9_8.x86_64 3/3 \r\n Verifying : postgresql-13.23-5.el9_8.x86_64 1/3 \r\n Verifying : postgresql-private-libs-13.23-5.el9_8.x86_64 2/3 \r\n Verifying : postgresql-server-13.23-5.el9_8.x86_64 3/3 \r\nInstalled products updated.\r\n\r\nInstalled:\r\n postgresql-13.23-5.el9_8.x86_64 postgresql-private-libs-13.23-5.el9_8.x86_64 \r\n postgresql-server-13.23-5.el9_8.x86_64 \r\n\r\nComplete!\r\n[root@labvmrhel01 ~]# postgresql-setup --initdb\r\n * Initializing database in \'/var/lib/pgsql/data\'\r\n * Initialized, logs are in /var/lib/pgsql/initdb_postgresql.log\r\n[root@labvmrhel01 ~]# systemctl enable --now postgresql\r\nCreated symlink /etc/systemd/system/multi-user.target.wants/postgresql.service → /usr/lib/systemd/system/postgresql.service.\r\n[root@labvmrhel01 ~]# rpm -i https://ftp.postgresql.org/pub/pgadmin/pgadmin4/yum/pgadmin4-redhat-repo-2-1.noarch.rpm\r\nwarning: /var/tmp/rpm-tmp.7QnBb3: Header V4 RSA/SHA256 Signature, key ID 210976f2: NOKEY\r\n[root@labvmrhel01 ~]# dnf install -y pgadmin4\r\nUpdating Subscription Management repositories.\r\npgadmin4 866 B/s | 833 B 00:00 \r\npgadmin4 3.4 MB/s | 3.8 kB 00:00 \r\nImporting GPG key 0x210976F2:\r\n Userid : \"Package Manager (Package Signing Key) <packages@pgadmin.org>\"\r\n Fingerprint: E869 7E2E EF76 C02D 3A63 3277 8881 B2A8 2109 76F2\r\n From : /etc/pki/rpm-gpg/PGADMIN_PKG_KEY\r\npgadmin4 634 kB/s | 3.4 MB 00:05 \r\nLast metadata expiration check: 0:00:06 ago on Wed 26 Aug 2026 03:12:15 PM CET.\r\nDependencies resolved.\r\n=========================================================================================\r\n Package Arch Version Repository Size\r\n=========================================================================================\r\nInstalling:\r\n pgadmin4 noarch 9.17-1.el9 pgAdmin4 6.3 k\r\nInstalling dependencies:\r\n libpq5 x86_64 18.4-1PGDG.rhel9.8 pgAdmin4 289 k\r\n replacing libpq.x86_64 13.23-3.el9_8\r\n pgadmin4-desktop x86_64 9.17-1.el9 pgAdmin4 92 M\r\n pgadmin4-server x86_64 9.17-1.el9 pgAdmin4 124 M\r\n pgadmin4-web noarch 9.17-1.el9 pgAdmin4 9.3 k\r\n python3-mod_wsgi x86_64 4.7.1-12.el9_6 rhel-9-for-x86_64-appstream-rpms 1.0 M\r\n\r\nTransaction Summary\r\n=========================================================================================\r\nInstall 6 Packages\r\n\r\nTotal download size: 217 M\r\nDownloading Packages:\r\n(1/6): pgadmin4-9.17-1.el9.noarch.rpm 17 kB/s | 6.3 kB 00:00 \r\n(2/6): libpq5-18.4-1PGDG.rhel9.8.x86_64.rpm 125 kB/s | 289 kB 00:02 \r\n(3/6): pgadmin4-web-9.17-1.el9.noarch.rpm 4.8 kB/s | 9.3 kB 00:01 \r\n(4/6): python3-mod_wsgi-4.7.1-12.el9_6.x86_64.rpm 137 kB/s | 1.0 MB 00:07 \r\n(5/6): pgadmin4-server-9.17-1.el9.x86_64.rpm 742 kB/s | 124 MB 02:51 \r\n(6/6): pgadmin4-desktop-9.17-1.el9.x86_64.rpm 380 kB/s | 92 MB 04:07 \r\n-----------------------------------------------------------------------------------------\r\nTotal 900 kB/s | 217 MB 04:07 \r\npgadmin4 3.8 MB/s | 3.8 kB 00:00 \r\nImporting GPG key 0x210976F2:\r\n Userid : \"Package Manager (Package Signing Key) <packages@pgadmin.org>\"\r\n Fingerprint: E869 7E2E EF76 C02D 3A63 3277 8881 B2A8 2109 76F2\r\n From : /etc/pki/rpm-gpg/PGADMIN_PKG_KEY\r\nKey imported successfully\r\nRunning transaction check\r\nTransaction check succeeded.\r\nRunning transaction test\r\nTransaction test succeeded.\r\nRunning transaction\r\n Preparing : 1/1 \r\n Installing : python3-mod_wsgi-4.7.1-12.el9_6.x86_64 1/7 \r\n Installing : libpq5-18.4-1PGDG.rhel9.8.x86_64 2/7 \r\n Running scriptlet: libpq5-18.4-1PGDG.rhel9.8.x86_64 2/7 \r\n Running scriptlet: pgadmin4-server-9.17-1.el9.x86_64 3/7 \r\n Installing : pgadmin4-server-9.17-1.el9.x86_64 3/7 \r\n Installing : pgadmin4-desktop-9.17-1.el9.x86_64 4/7 \r\n Running scriptlet: pgadmin4-desktop-9.17-1.el9.x86_64 4/7 \r\n Installing : pgadmin4-web-9.17-1.el9.noarch 5/7 \r\n Installing : pgadmin4-9.17-1.el9.noarch 6/7 \r\n Obsoleting : libpq-13.23-3.el9_8.x86_64 7/7 \r\n Running scriptlet: libpq-13.23-3.el9_8.x86_64 7/7 \r\n Verifying : libpq5-18.4-1PGDG.rhel9.8.x86_64 1/7 \r\n Verifying : libpq-13.23-3.el9_8.x86_64 2/7 \r\n Verifying : pgadmin4-9.17-1.el9.noarch 3/7 \r\n Verifying : pgadmin4-desktop-9.17-1.el9.x86_64 4/7 \r\n Verifying : pgadmin4-server-9.17-1.el9.x86_64 5/7 \r\n Verifying : pgadmin4-web-9.17-1.el9.noarch 6/7 \r\n Verifying : python3-mod_wsgi-4.7.1-12.el9_6.x86_64 7/7 \r\nInstalled products updated.\r\n\r\nInstalled:\r\n libpq5-18.4-1PGDG.rhel9.8.x86_64 pgadmin4-9.17-1.el9.noarch \r\n pgadmin4-desktop-9.17-1.el9.x86_64 pgadmin4-server-9.17-1.el9.x86_64 \r\n pgadmin4-web-9.17-1.el9.noarch python3-mod_wsgi-4.7.1-12.el9_6.x86_64 \r\n\r\nComplete!\r\n[root@labvmrhel01 ~]# /usr/pgadmin4/bin/setup-web.sh\r\nSetting up pgAdmin 4 in web mode on a Redhat based platform...\r\nCreating configuration database...\r\n/usr/pgadmin4/venv/lib64/python3.9/site-packages/passlib/pwd.py:16: UserWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html. The pkg_resources package is slated for removal as early as 2025-11-30. Refrain from using this package or pin to Setuptools<81.\r\n import pkg_resources\r\nNOTE: Configuring authentication for SERVER mode.\r\n\r\nEnter the email address and password to use for the initial pgAdmin user account:\r\n\r\nEmail address: khelaf.hanifi@liebherr.com\r\nPassword: \r\nRetype password:\r\n/usr/pgadmin4/venv/lib64/python3.9/site-packages/google/api_core/_python_version_support.py:242: FutureWarning: You are using a non-supported Python version (3.9.25). Google will not post any further updates to google.api_core supporting this Python version. Please upgrade to the latest Python version, or at least Python 3.10, and then update google.api_core.\r\n warnings.warn(message, FutureWarning)\r\n/usr/pgadmin4/venv/lib64/python3.9/site-packages/google/auth/__init__.py:54: FutureWarning: You are using a Python version 3.9 past its end of life. Google will update google-auth with critical bug fixes on a best-effort basis, but not with any other fixes or features. Please upgrade your Python version, and then update google-auth.\r\n warnings.warn(eol_message.format(\"3.9\"), FutureWarning)\r\n/usr/pgadmin4/venv/lib64/python3.9/site-packages/google/oauth2/__init__.py:40: FutureWarning: You are using a Python version 3.9 past its end of life. Google will update google-auth with critical bug fixes on a best-effort basis, but not with any other fixes or features. Please upgrade your Python version, and then update google-auth.\r\n warnings.warn(eol_message.format(\"3.9\"), FutureWarning)\r\npgAdmin 4 - Application Initialisation\r\n======================================\r\n\r\nCreating storage and log directories...\r\nConfiguring SELinux...\r\nThe Apache web server is not running. We can enable and start the web server for you to finish pgAdmin 4 installation. Continue (y/n)? y\r\nCreated symlink /etc/systemd/system/multi-user.target.wants/httpd.service → /usr/lib/systemd/system/httpd.service.\r\nApache successfully enabled.\r\nApache successfully started.\r\nYou can now start using pgAdmin 4 in web mode at http://127.0.0.1/pgadmin4\r\n[root@labvmrhel01 ~]# sudo -u postgres psql -c \"ALTER USER postgres WITH PASSWORD \'Rhel2024+\';\"\r\ncould not change directory to \"/root\": Permission denied\r\nALTER ROLE\r\n[root@labvmrhel01 ~]# sed -i \'s/127.0.0.1\\/32 ident/127.0.0.1\\/32 scram-sha-256/g\' /var/lib/pgsql/data/pg_hba.conf\r\nsystemctl restart postgresql\r\n[root@labvmrhel01 ~]# sed -i \'s/scram-sha-256/trust/g\' /var/lib/pgsql/data/pg_hba.conf\r\nsystemctl restart postgresql\r\nsudo -u postgres psql -c \"ALTER USER postgres WITH PASSWORD \'Rhel2024+\';\"\r\nsed -i \'s/trust/scram-sha-256/g\' /var/lib/pgsql/data/pg_hba.conf\r\nsystemctl restart postgresql\r\ncould not change directory to \"/root\": Permission denied\r\nALTER ROLE\r\n[root@labvmrhel01 ~]# sed -i \'s/scram-sha-256/trust/g\' /var/lib/pgsql/data/pg_hba.conf\r\nsystemctl restart postgresql\r\n[root@labvmrhel01 ~]# dnf module enable -y nodejs:20\r\nUpdating Subscription Management repositories.\r\nLast metadata expiration check: 0:55:11 ago on Wed 26 Aug 2026 03:12:15 PM CET.\r\nDependencies resolved.\r\n=========================================================================================\r\n Package Architecture Version Repository Size\r\n=========================================================================================\r\nEnabling module streams:\r\n nodejs 20 \r\n\r\nTransaction Summary\r\n=========================================================================================\r\n\r\nComplete!\r\n[root@labvmrhel01 ~]# dnf install -y nodejs\r\nUpdating Subscription Management repositories.\r\n\r\nThe system clock is skewed. There is a time difference of 9.0 seconds with the entitlement server. Please check your clock settings to ensure access to all entitled content.\r\n\r\nLast metadata expiration check: 0:56:49 ago on Wed 26 Aug 2026 03:12:15 PM CET.\r\nDependencies resolved.\r\n=========================================================================================\r\n Package Arch Version Repository Size\r\n=========================================================================================\r\nInstalling:\r\n nodejs x86_64 1:20.20.2-1.module+el9.7.0+24193+41b7b572\r\n rhel-9-for-x86_64-appstream-rpms 14 M\r\nInstalling weak dependencies:\r\n nodejs-docs noarch 1:20.20.2-1.module+el9.7.0+24193+41b7b572\r\n rhel-9-for-x86_64-appstream-rpms 8.6 M\r\n nodejs-full-i18n x86_64 1:20.20.2-1.module+el9.7.0+24193+41b7b572\r\n rhel-9-for-x86_64-appstream-rpms 8.9 M\r\n npm x86_64 1:10.8.2-1.20.20.2.1.module+el9.7.0+24193+41b7b572\r\n rhel-9-for-x86_64-appstream-rpms 2.3 M\r\n\r\nTransaction Summary\r\n=========================================================================================\r\nInstall 4 Packages\r\n\r\nTotal download size: 34 M\r\nInstalled size: 181 M\r\nDownloading Packages:\r\n[MIRROR] nodejs-docs-20.20.2-1.module+el9.7.0+24193+41b7b572.noarch.rpm: Curl error (6): Couldn\'t resolve host name for https://cdn.redhat.com/content/dist/rhel9/9/x86_64/appstream/os/Packages/n/nodejs-docs-20.20.2-1.module%2bel9.7.0%2b24193%2b41b7b572.noarch.rpm [Could not resolve host: cdn.redhat.com]\r\n[MIRROR] nodejs-full-i18n-20.20.2-1.module+el9.7.0+24193+41b7b572.x86_64.rpm: Curl error (6): Couldn\'t resolve host name for https://cdn.redhat.com/content/dist/rhel9/9/x86_64/appstream/os/Packages/n/nodejs-full-i18n-20.20.2-1.module%2bel9.7.0%2b24193%2b41b7b572.x86_64.rpm [Could not resolve host: cdn.redhat.com]\r\n[MIRROR] nodejs-20.20.2-1.module+el9.7.0+24193+41b7b572.x86_64.rpm: Curl error (6): Couldn\'t resolve host name for https://cdn.redhat.com/content/dist/rhel9/9/x86_64/appstream/os/Packages/n/nodejs-20.20.2-1.module%2bel9.7.0%2b24193%2b41b7b572.x86_64.rpm [Could not resolve host: cdn.redhat.com]\r\n[MIRROR] nodejs-docs-20.20.2-1.module+el9.7.0+24193+41b7b572.noarch.rpm: Curl error (6): Couldn\'t resolve host name for https://cdn.redhat.com/content/dist/rhel9/9/x86_64/appstream/os/Packages/n/nodejs-docs-20.20.2-1.module%2bel9.7.0%2b24193%2b41b7b572.noarch.rpm [Could not resolve host: cdn.redhat.com]\r\n[FAILED] nodejs-docs-20.20.2-1.module+el9.7.0+24193+41b7b572.noarch.rpm: No more mirrors to try - All mirrors were already tried without success\r\n(2-3/4): nodejs-20.20.2-1 25% [====== ] 5.1 GB/s | 8.6 MB 00:00 ETA\r\nThe downloaded packages were saved in cache until the next successful transaction.\r\nYou can remove cached packages by executing \'dnf clean packages\'.\r\nError: Error downloading packages:\r\n nodejs-docs-1:20.20.2-1.module+el9.7.0+24193+41b7b572.noarch: Cannot download, all mirrors were already tried without success\r\n[root@labvmrhel01 ~]# node -v\r\nnpm -v\r\nbash: node: command not found...\r\nInstall package \'nodejs\' to provide command \'node\'? [N/y] n\r\n\r\n\r\nbash: npm: command not found...\r\nInstall package \'npm\' to provide command \'npm\'? [N/y] n\r\n\r\n\r\n[root@labvmrhel01 ~]# dnf install -y nodejs\r\nUpdating Subscription Management repositories.\r\nRed Hat Enterprise Linux 9 for x86_64 - AppStream (RPMs) 587 B/s | 4.5 kB 00:07 \r\nRed Hat Enterprise Linux 9 for x86_64 - AppStream (RPMs) 195 kB/s | 108 MB 09:23 \r\nLast metadata expiration check: 0:06:25 ago on Wed 26 Aug 2026 04:17:23 PM CET.\r\nDependencies resolved.\r\n=========================================================================================\r\n Package Arch Version Repository Size\r\n=========================================================================================\r\nInstalling:\r\n nodejs x86_64 1:20.20.2-1.module+el9.7.0+24193+41b7b572\r\n rhel-9-for-x86_64-appstream-rpms 14 M\r\nInstalling weak dependencies:\r\n nodejs-docs noarch 1:20.20.2-1.module+el9.7.0+24193+41b7b572\r\n rhel-9-for-x86_64-appstream-rpms 8.6 M\r\n nodejs-full-i18n x86_64 1:20.20.2-1.module+el9.7.0+24193+41b7b572\r\n rhel-9-for-x86_64-appstream-rpms 8.9 M\r\n npm x86_64 1:10.8.2-1.20.20.2.1.module+el9.7.0+24193+41b7b572\r\n rhel-9-for-x86_64-appstream-rpms 2.3 M\r\n\r\nTransaction Summary\r\n=========================================================================================\r\nInstall 4 Packages\r\n\r\nTotal download size: 34 M\r\nInstalled size: 181 M\r\nDownloading Packages:\r\n[MIRROR] nodejs-docs-20.20.2-1.module+el9.7.0+24193+41b7b572.noarch.rpm: Curl error (56): Failure when receiving data from the peer for https://cdn.redhat.com/content/dist/rhel9/9/x86_64/appstream/os/Packages/n/nodejs-docs-20.20.2-1.module%2bel9.7.0%2b24193%2b41b7b572.noarch.rpm [OpenSSL SSL_read: Connection reset by peer, errno 104]\r\n(1/4): nodejs-docs-20.20.2-1.module+el9.7.0+24193+41b7b5 98 kB/s | 8.6 MB 01:30 \r\n(2/4): nodejs-full-i18n-20.20.2-1.module+el9.7.0+24193+4 94 kB/s | 8.9 MB 01:36 \r\n(3/4): npm-10.8.2-1.20.20.2.1.module+el9.7.0+24193+41b7b 210 kB/s | 2.3 MB 00:11 \r\n(4/4): nodejs-20.20.2-1.module+el9.7.0+24193+41b7b572.x8 81 kB/s | 14 MB 02:58 \r\n-----------------------------------------------------------------------------------------\r\nTotal 195 kB/s | 34 MB 02:58 \r\nRunning transaction check\r\nTransaction check succeeded.\r\nRunning transaction test\r\nTransaction test succeeded.\r\nRunning transaction\r\n Preparing : 1/1 \r\n Installing : nodejs-docs-1:20.20.2-1.module+el9.7.0+24193+41b7b572.noarch 1/4 \r\n Installing : nodejs-full-i18n-1:20.20.2-1.module+el9.7.0+24193+41b7b572.x8 2/4 \r\n Installing : npm-1:10.8.2-1.20.20.2.1.module+el9.7.0+24193+41b7b572.x86_64 3/4 \r\n Installing : nodejs-1:20.20.2-1.module+el9.7.0+24193+41b7b572.x86_64 4/4 \r\n Running scriptlet: nodejs-1:20.20.2-1.module+el9.7.0+24193+41b7b572.x86_64 4/4 \r\n Verifying : nodejs-1:20.20.2-1.module+el9.7.0+24193+41b7b572.x86_64 1/4 \r\n Verifying : nodejs-docs-1:20.20.2-1.module+el9.7.0+24193+41b7b572.noarch 2/4 \r\n Verifying : nodejs-full-i18n-1:20.20.2-1.module+el9.7.0+24193+41b7b572.x8 3/4 \r\n Verifying : npm-1:10.8.2-1.20.20.2.1.module+el9.7.0+24193+41b7b572.x86_64 4/4 \r\nInstalled products updated.\r\n\r\nInstalled:\r\n nodejs-1:20.20.2-1.module+el9.7.0+24193+41b7b572.x86_64 \r\n nodejs-docs-1:20.20.2-1.module+el9.7.0+24193+41b7b572.noarch \r\n nodejs-full-i18n-1:20.20.2-1.module+el9.7.0+24193+41b7b572.x86_64 \r\n npm-1:10.8.2-1.20.20.2.1.module+el9.7.0+24193+41b7b572.x86_64 \r\n\r\nComplete!\r\n[root@labvmrhel01 ~]# node -v\r\nv20.20.2\r\n[root@labvmrhel01 ~]# npm -v\r\n10.8.2\r\n
Author: Hanifi Khelaf | Date: 2026-08-27 10:10:25
Blog N° 35
Title: Neutrino
Content:
La double dĂ©sintĂ©gration bĂȘta sans neutrino rĂ©unit en un seul phĂ©nomĂšne l\'Ă©nigme du temps inversĂ©, la nature du neutrino et la survie de la matiĂšre dans notre univers.\r\n​1. Le neutrino : la plus petite matiĂšre\r\nLe neutrino est la particule de matiĂšre la plus lĂ©gĂšre et la plus insaisissable. Si la double dĂ©sintĂ©gration bĂȘta se produit sans Ă©mettre de neutrinos, cela prouve que le neutrino est sa propre antiparticule (particule de Majorana) et qu\'il peut s\'annihiler lui-mĂȘme.\r\n​2. Le temps inversĂ© et l\'anti-univers\r\nSelon la symĂ©trie CPT et les Ă©quations de Feynman, une antiparticule agit exactement comme une particule de matiĂšre qui remonte le temps. Le Big Bang a ainsi pu produire deux rĂ©alitĂ©s miroirs : notre univers de matiĂšre qui progresse vers le futur et un anti-univers d\'antimatiĂšre qui s\'Ă©tend vers le passĂ©.\r\n​3. Pourquoi la matiĂšre a gagnĂ©\r\nAu tout dĂ©but, matiĂšre et antimatiĂšre ont Ă©tĂ© créées en quantitĂ©s presque identiques et se sont annihilĂ©es en pur rayonnement. Si le neutrino est sa propre antiparticule, ce processus rompt l\'Ă©quilibre : un surplus infime de matiĂšre (une particule restante pour chaque milliard de paires créées) a suffi pour dĂ©truire toute l\'antimatiĂšre et former nos Ă©toiles, nos planĂštes et tout ce qui existe.
Author: Hanifi khelaf | Date: 2026-08-25 21:46:54
Blog N° 34
Title: Veeam Data Platform V13.1
Content:
From Hypervisor Freedom to Identity Recovery: Get Ready for Veeam Data Platform v13.1\r\n\r\nhttps://www.youtube.com/watch?v=o-eZvXAf05I
Author: Hanifi Khelaf | Date: 2026-08-18 21:25:25
Blog N° 33
Title: Ctrl + Z
Content:
C\'est la magie absolue du dev ! Ctrl + Z (Annuler / Undo), c\'est littĂ©ralement le bouton \"Machine Ă  remonter le temps\" et le meilleur ami de tout dĂ©veloppeur.\r\n\r\nTant que tu n\'as pas fermĂ© ton Ă©diteur de code, il conserve en mĂ©moire toutes tes frappes et modifications rĂ©centes.\r\n\r\n💡 Deux petits raccourcis bonus Ă  garder sous le coude :\r\nCtrl + Y (ou Ctrl + Shift + Z) : C\'est l\'inverse (RĂ©tablir / Redo). Si tu fais un Ctrl + Z de trop et que tu effaces un truc bien, ça te permet de revenir en avant.\r\n\r\nCtrl + S : Sauvegarder immĂ©diatement.
Author: Hanifi Khelaf | Date: 2026-08-01 13:37:05
Blog N° 32
Title: utf8mb4 ET LA GESTION DES EMOJIS EN BDD (MySQL / MariaDB)
Content:
Dans MySQL et MariaDB, l\'encodage \'utf8mb4\' (UTF-8 4-Byte) est le standard \r\nindispensable pour stocker l\'intĂ©gralitĂ© du jeu de caractĂšres Unicode, \r\nnotamment les Ă©mojis.\r\n\r\n--------------------------------------------------------------------------------\r\n1. POURQUOI LE \'utf8\' CLASSIQUE DE MYSQL NE SUFFIT PAS ?\r\n--------------------------------------------------------------------------------\r\n\r\nHistoriquement, le type \'utf8\' dans MySQL (dĂ©sormais nommĂ© \'utf8mb3\') Ă©tait \r\nune version incomplĂšte d\'UTF-8 :\r\n\r\n* \'utf8\' (utf8mb3) : LimitĂ© Ă  3 octets maximum par caractĂšre. Il ne couvre que \r\n le plan multilingue de base (U+0000 Ă  U+FFFF).\r\n* \'utf8mb4\' : Utilise jusqu\'Ă  4 octets par caractĂšre. Il couvre l\'ensemble du \r\n standard Unicode (U+0000 Ă  U+10FFFF).\r\n\r\nLe problĂšme avec les Ă©mojis :\r\nLa majoritĂ© des Ă©mojis (comme đŸ€– U+1F916, 🚀 U+1F680, 😂 U+1F602) se trouvent \r\ndans les plans supĂ©rieurs d\'Unicode et nĂ©cessitent 4 octets.\r\n\r\nSi vous tentez d\'insĂ©rer un Ă©moji dans une colonne \'utf8\' classique :\r\n* MySQL gĂ©nĂšre l\'erreur : \"#1366 - Incorrect string value\".\r\n* Ou le texte est tronquĂ© juste avant l\'Ă©moji (selon le mode strict du serveur).\r\n\r\n--------------------------------------------------------------------------------\r\n2. LES COLLATIONS utf8mb4 : LAQUELLE CHOISIR ?\r\n--------------------------------------------------------------------------------\r\n\r\nLa collation dĂ©finit la maniĂšre dont les caractĂšres sont comparĂ©s et triĂ©s \r\n(gestion des accents et des majuscules/minuscules).\r\n\r\n* utf8mb4_0900_ai_ci :\r\n Standard sous MySQL 8.0+. BasĂ© sur Unicode 9.0. Accent-insensitive & Case-insensitive.\r\n -> RecommandĂ© pour MySQL 8.0+\r\n\r\n* utf8mb4_unicode_ci :\r\n Standard sous MySQL 5.7 et MariaDB. Respecte les rĂšgles de tri internationales.\r\n -> RecommandĂ© pour MariaDB / MySQL 5.7\r\n\r\n* utf8mb4_general_ci :\r\n Plus ancienne et rapide, mais moins prĂ©cise sur les tris complexes ou caractĂšres spĂ©ciaux.\r\n -> À Ă©viter sur de nouveaux projets\r\n\r\n--------------------------------------------------------------------------------\r\n3. CONFIGURATION COMPLÈTE (BDD, TABLE, COLONNE, PHP, SERVEUR)\r\n--------------------------------------------------------------------------------\r\n\r\nA. Au niveau de la Base de DonnĂ©es / Table / Colonne (SQL) :\r\n\r\n-- 1. Base de donnĂ©es complĂšte\r\nALTER DATABASE nom_de_bdd CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci;\r\n\r\n-- 2. Table spĂ©cifique\r\nALTER TABLE nom_de_table CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;\r\n\r\n-- 3. Colonne spĂ©cifique\r\nALTER TABLE nom_de_table MODIFY nom_colonne VARCHAR(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;\r\n\r\nB. Au niveau de la connexion PHP :\r\n\r\n* Avec PDO :\r\n $dsn = \"mysql:host=localhost;dbname=ma_bdd;charset=utf8mb4\";\r\n $pdo = new PDO($dsn, $user, $password);\r\n\r\n* Avec mysqli :\r\n $mysqli = new mysqli(\"localhost\", \"user\", \"password\", \"ma_bdd\");\r\n $mysqli->set_charset(\"utf8mb4\");\r\n\r\nC. Au niveau du serveur MySQL (my.cnf / my.ini) :\r\n\r\n[client]\r\ndefault-character-set = utf8mb4\r\n\r\n[mysql]\r\ndefault-character-set = utf8mb4\r\n\r\n[mysqld]\r\ncharacter-set-client-handshake = FALSE\r\ncharacter-set-server = utf8mb4\r\ncollation-server = utf8mb4_unicode_ci\r\n\r\n--------------------------------------------------------------------------------\r\n4. EN RÉSUMÉ (RÈGLE D\'OR)\r\n--------------------------------------------------------------------------------\r\n\r\nPour tout nouveau projet Web ou base de donnĂ©es MySQL/MariaDB, utilisez \'utf8mb4\' \r\npar dĂ©faut sur vos bases, tables, connexions PHP et scripts. Cela Ă©vite les erreurs \r\nd\'encodage avec les Ă©mojis, les caractĂšres chinois/arabes ou les symboles \r\nmathĂ©matiques complexes.
Author: Hanifi Khelaf | Date: 2026-07-31 17:38:42
Blog N° 31
Title: /?var=valeur-token
Content:
Ce paramĂštre /?hl=fr-FR est un paramĂštre standard de sĂ©lection de langue (Host Language ou Human Language).\r\n\r\n📌 Signification\r\nhl : Sigle pour Host Language (ou Human Language).\r\n\r\nfr-FR : Code ISO de la langue, ici Français (France).
Author: Hanifi Neila | Date: 2026-08-01 13:37:05
Blog N° 30
Title: Nettoyage de l\'URL cÎté navigateur (Clean URL)
Content:
// Conserver la provenance en session puis nettoyer l\'URL\r\nconst urlParams = new URLSearchParams(window.location.search);\r\nif (urlParams.has(\'fbclid\')) {\r\n // 1. Sauvegarder dans la session du navigateur\r\n sessionStorage.setItem(\'fbclid\', urlParams.get(\'fbclid\'));\r\n \r\n // 2. Retirer le paramĂštre de la barre d\'adresse proprement\r\n urlParams.delete(\'fbclid\');\r\n const cleanUrl = window.location.pathname + (urlParams.toString() ? \'?\' + urlParams.toString() : \'\');\r\n window.history.replaceState({}, document.title, cleanUrl);\r\n}
Author: Hanifi Sophia | Date: 2026-08-01 13:37:05
Blog N° 29
Title: PHP-CGI Argument Injection Attack (Remote Code Execution)
Content:
📌 Overview\r\nThis log entry shows a PHP-CGI Argument Injection attack, a critical vulnerability (associated with CVE-2024-4577 and CVE-2012-1823) that targets servers running PHP in CGI mode.\r\n\r\nThe attacker is attempting to inject command-line arguments directly into the PHP binary to override server configurations and achieve Remote Code Execution (RCE).\r\n\r\n🔍 Payload Breakdown\r\nThe intercepted string is:\r\n\r\nPlaintext\r\n/?%ADd+allow_url_include%3d1+%ADd+auto_prepend_file%3dphp://input\r\n%ADd / -d (Argument Injection):\r\nWhen PHP runs via CGI, query string parameters can be passed directly as CLI flags to the php executable. The -d flag allows setting custom php.ini directives. Attackers often use %ADd (using a soft-hyphen character bypass) to trick Web Application Firewalls (WAFs) and bypass simple string filters.\r\n\r\nallow_url_include=1 (Enabling Remote Streams):\r\nThis directive forces PHP to allow including external wrappers and URLs. By default, this is disabled in secure PHP installations to prevent code execution via remote resources.\r\n\r\nauto_prepend_file=php://input (Payload Execution):\r\nThis directive instructs PHP to automatically include and execute a file before processing the requested web page. By setting it to php://input, PHP is forced to read and execute whatever raw PHP code the attacker sends in the HTTP POST request body.\r\n\r\nđŸ’„ Impact\r\nSeverity: CRITICAL\r\n\r\nType: Remote Code Execution (RCE)\r\n\r\nIf successful, the attacker can execute arbitrary PHP or system commands on your server with the privileges of the web server process (e.g., www-data).\r\n\r\nđŸ›Ąïž Mitigation & Prevention\r\nUpdate PHP: Ensure you are using a patched and supported version of PHP.\r\n\r\nMove Away from PHP-CGI: Switch from php-cgi to PHP-FPM (FastCGI Process Manager) or FastCGI handlers.\r\n\r\nWAF Rules: Implement WAF or Nginx/Apache rewrite rules to block incoming queries containing command-line directives like -d, %2dd, or %ADd.
Author: Khelaf | Date: 2026-08-01 13:37:05
Blog N° 28
Title: AJAX
Content:
AJAX est l\'acronyme de Asynchronous JavaScript And XML (mĂȘme si aujourd\'hui on utilise pratiquement toujours du JSON Ă  la place du XML).\r\n\r\nPour le dire trĂšs simplement : C\'est la technologie qui permet d\'Ă©changer des donnĂ©es avec le serveur en arriĂšre-plan, sans recharger la page web.
Author: AhnizTech | Date: 2026-07-31 17:38:42
Blog N° 27
Title: Supervised Learning labeled data
Content:
Well, the data set with past house sales transactions contained both known prices and features of the\r\n\r\nhomes.\r\n\r\nWe didn\'t merely highlight home features.\r\n\r\nThis is an example of supervised learning too, but it\'s used for prediction, also called a regression\r\n\r\nproblem.\r\n\r\nWhen a user inputs the characteristics of a new home into the app, the app predicts the new home\'s\r\n\r\nprice based on its features and historical information for similar homes.\r\n\r\nSo, simply put, in supervised learning, we explicitly train the model with known outputs to guide\r\n\r\nits learning.
Author: AhnizTech | Date: 2026-07-12 13:59:19
Blog N° 26
Title: You hit the hits limit ( technic)
Content:
Un \"hit\" (parfois traduit par \"requĂȘte\" ou \"appel\") est une unitĂ© de mesure technique trĂšs prĂ©cise.\r\n\r\nContrairement Ă  une \"visite\" (une personne qui vient sur votre site), un hit reprĂ©sente chaque fichier individuel que le serveur doit envoyer pour afficher une page.\r\n\r\nVoici comment ça fonctionne concrĂštement :\r\nQuand un habitant de votre district ouvre la page d\'accueil de votre portail Tizi Tifra, le serveur ne compte pas \"1\". Il compte :\r\n\r\n1 hit pour le fichier HTML.\r\n\r\n1 hit pour le fichier CSS (le style).\r\n\r\n1 hit pour chaque image prĂ©sente sur la page (si vous avez 10 photos d\'archives, ça fait 10 hits).\r\n\r\n1 hit pour chaque script JavaScript.\r\n\r\nRĂ©sultat : Une seule visite d\'une minute sur une page riche en photos peut gĂ©nĂ©rer 40 ou 50 hits Ă  elle seule.\r\n\r\nPourquoi InfinityFree compte les hits et pas seulement les visiteurs ?\r\nParce que chaque hit consomme des ressources sur leur serveur (processeur et mĂ©moire).\r\n\r\nSi vous avez un site trĂšs lĂ©ger (juste du texte), 50 000 hits correspondent Ă  beaucoup de visiteurs.\r\n\r\nSi vous avez un site trĂšs lourd (beaucoup d\'images haute dĂ©finition, beaucoup de scripts), vous atteindrez la limite de 50 000 hits trĂšs rapidement, mĂȘme avec peu de visiteurs.
Author: Hanifi Khelaf | Date: 2026-04-02 16:33:36
Blog N° 25
Title: Adguard DNS privé
Content:
Pour supprimer la majoritĂ© des publicitĂ©s et des fenĂȘtres surgissantes (pop-ups) sur votre smartphone, vous pouvez utiliser un DNS PrivĂ©.\r\n​C\'est quoi ?\r\n​C\'est un filtre intelligent : lorsqu\'un site ou une application tente d\'afficher une publicitĂ©, le serveur bloque la connexion avant mĂȘme que l\'image ou la fenĂȘtre n\'apparaisse.\r\n​Comment l\'activer ?\r\n​Allez dans les ParamĂštres de votre tĂ©lĂ©phone.\r\n​Cherchez Connexion et partage (ou tapez \"DNS\" dans la barre de recherche).\r\n​SĂ©lectionnez DNS privĂ©.\r\n​Choisissez l\'option DNS spĂ©cifiĂ© (ou \"Nom d\'hĂŽte\").\r\n​Tapez l\'adresse : dns.adguard.com\r\n​Enregistrez.\r\n​Les avantages\r\n​✅ Stop aux pubs : Nettoie les navigateurs et les applications gratuites.\r\n​✅ Économie : Moins de donnĂ©es consommĂ©es et gain de batterie.\r\n​✅ Discret : Aucune application Ă  installer, ne ralentit pas le tĂ©lĂ©phone.
Author: AhnizTech | Date: 2026-03-29 13:17:06
Blog N° 24
Title: Losanges bizarres symbol ĂŻ
Content:
<?php\r\n mysqli_set_charset($conn, \"utf8mb4\");(Ajoute cette ligne juste avant ta requĂȘte)\r\n $query_photos = \"SELECT * FROM village_photos WHERE statut = \'valide\' ORDER BY date_soumission DESC\"; \r\n\r\nC\'est exactement lĂ  qu\'il fallait le placer. En dĂ©clarant le utf8mb4 juste avant de lancer la requĂȘte, tu forces PHP Ă  sortir les donnĂ©es de la table avec le bon \"alphabet\", ce qui Ă©vite au navigateur de paniquer et de remplacer les ĂŻ ou les Ă© par des losanges bizarres.
Author: Hanifi Khelaf | Date: 2026-03-09 14:59:00
Blog N° 23
Title: stack Full-Stack (Node.js, Express, PostgreSQL, Bcrypt, EJS) in RHEL
Content:
stack Full-Stack (Node.js, Express, PostgreSQL, Bcrypt, EJS) sur ta machine Red Hat. Voici ton rĂ©sumĂ© global structurĂ© pour servir de guide de rĂ©fĂ©rence lors de ton passage sur un futur VPS.\r\n\r\n📂 1. HiĂ©rarchie Standard du Projet\r\nC\'est la structure indispensable pour que Node.js et Express trouvent tes fichiers :\r\n\r\n⚙ 2. Configuration Technique (Checklist)\r\nPour qu\'un VPS fonctionne comme ta VM actuelle, vĂ©rifie ces points :\r\n\r\nLe Fichier package.json : Doit contenir \"type\": \"module\" pour utiliser les import.\r\n\r\nLes DĂ©pendances : express, pg (PostgreSQL), bcrypt (sĂ©curitĂ©), ejs (moteur de template) et body-parser (lecture des formulaires).\r\n\r\nBase de DonnĂ©es : Ta table users doit avoir un champ email UNIQUE et un champ password TEXT pour stocker les hachages Bcrypt.\r\n\r\nđŸ›Ąïž 3. SĂ©curitĂ© : Le Concept Bcrypt\r\nC\'est ce que tu as implĂ©mentĂ© avec succĂšs :\r\n\r\nRegister : On ne stocke jamais le mot de passe en clair. On utilise bcrypt.hash() pour crĂ©er une empreinte numĂ©rique.\r\n\r\nLogin : On rĂ©cupĂšre l\'utilisateur par son email, puis on utilise bcrypt.compare() pour vĂ©rifier si le mot de passe saisi correspond au hachage en base.\r\n\r\n🚀 4. Commandes de Secours (Terminal)\r\nGarde ces commandes prĂ©cieusement pour relancer ton projet sur un VPS aprĂšs un reboot :\r\n\r\n💡 Prochaine Ă©tape pour ton VPS\r\nSur un vrai serveur exposĂ© sur internet, tu ne devras plus utiliser localhost mais configurer un Reverse Proxy (avec Nginx) et utiliser PM2 pour que ton application reste allumĂ©e 24h/24 mĂȘme si tu fermes ton terminal.
Author: Hanifi Khelaf | Date: 2026-03-05 15:06:23
Blog N° 22
Title: iLOT 4 Proliant
Content:
IPMI fonctionne de maniĂšre similaire Ă  iLO (Integrated Lights-Out) sur les serveurs HP ProLiant. iLO est en fait une implĂ©mentation propriĂ©taire d’HP basĂ©e sur le concept IPMI, offrant des fonctionnalitĂ©s avancĂ©es de gestion Ă  distance comme le contrĂŽle du serveur, le redĂ©marrage, la surveillance matĂ©rielle, et l’accĂšs Ă  la console mĂȘme quand le systĂšme d’exploitation ne rĂ©pond pas. Donc, IPMI est le standard gĂ©nĂ©ral, et iLO est la version spĂ©cifique d’HP avec des options souvent plus complĂštes. Si vous utilisez un serveur HP ProLiant, vous interagirez gĂ©nĂ©ralement via iLO pou
Author: Hanifi Khelaf | Date: 2025-11-11 20:21:15
Blog N° 21
Title: IPMI (Intelligent Platform Management Interface)
Content:
IPMI (Intelligent Platform Management Interface) est un protocole standard qui permet aux administrateurs de gĂ©rer et surveiller un serveur Ă  distance, mĂȘme si le systĂšme d’exploitation est Ă©teint, plantĂ© ou non installĂ©. GrĂące Ă  IPMI, on peut accĂ©der Ă  des fonctions comme le redĂ©marrage du serveur, la surveillance des tempĂ©ratures, des tensions, ou encore la gestion des logs matĂ©riels, via une interface rĂ©seau dĂ©diĂ©e. Cela se fait indĂ©pendamment du systĂšme d’exploitation principal, ce qui est trĂšs utile pour la maintenance et le dĂ©pannage Ă  distance. Si vous voulez, je peux vous expliquer comment accĂ©der ou utiliser l’IPMI sur votre serveur.
Author: Hanifi Khelaf | Date: 2025-11-11 20:03:22
Blog N° 20
Title: IPMI
Content:
IPMI
Author: Hanifi Khelaf | Date: 2025-11-11 20:02:26
Blog N° 19
Title: Pediatric Neurology (Neuropédiatrie)
Content:
Dr. Neuropédiatre SMAILI (Epse HANIFI) is a specialist in Pediatric Neurology in Algeria, practicing in Mohammadia, Algiers.
​Here are some details found:
​Specialty: Pediatric Neurology (NeuropĂ©diatrie)
​Location: CitĂ© 632 Logts Bt 49 Cabinet N°5 Mohammadia, Alger.
​Contact (Mobile): 0796 29 29 50
​Contact (Landline): 020 41 33 16
​Email: neuroped.smaili@gmail.com
​Services include: Consultation, follow-up, and specific exams like EEG (Electroencephalography) and management of various neurological conditions in children (epilepsy, developmental delay, etc.).
Author: Dr. SMAILI | Date: 2025-10-22 17:49:11
Blog N° 18
Title: PostgreSQL
Content:
PostgresSQL it is widely used by many of the top companies that you would have heard of, like, Apple, or Twitch, or Instagram, and even NASA uses Postgres to manage their data.
Author: Hanifi khelaf | Date: 2025-10-17 14:54:53
Blog N° 17
Title: PostgreSQL
Content:
PostgresSQL it is widely used by many of the top companies that you would have heard of, like, Apple, or Twitch, or Instagram, and even NASA uses Postgres to manage their data.
Author: Hanifi khelaf | Date: 2025-10-17 14:50:42
Blog N° 16
Title: Noble Einstein
Content:
1917 cosmologie scientifique. 1919
1921 le prix noble .
Author: Einstein | Date: 2025-10-16 23:41:40
Blog N° 15
Title: Espace relatif
Content:
Le temps est relatif... La simultanĂ©itĂ© distance et vitesse de la lumiĂšre. He had 1905... La thĂ©orie de relativitĂ© restreinte E= MC2 toute masse se transforme en Ă©nergie et et toute Ă©nergie transforme en masse. À 30 ans. Something is wrong. La vitesse annule la gravitĂ© assenceur grande vitesse vous flotter. 1909 la thĂ©orie relativitĂ© gĂ©nĂ©rale. RadioactivitĂ©...
Author: Einstein | Date: 2025-10-16 23:30:01
Blog N° 14
Title: CRUD
Content:
Create
Read
Update
Destroy
Author: DB | Date: 2025-10-16 20:41:10
Blog N° 13
Title: Dopamine
Content:
La dopamine est un neurotransmetteur, c’est-Ă -dire une molĂ©cule chimique qui permet la communication entre les neurones dans le cerveau. Elle joue un rĂŽle crucial dans de nombreuses fonctions cĂ©rĂ©brales et corporelles....la
Methamphetamine(meth) fait 6 fois la dopamine extrĂȘmement dangereuse pour le corps elle crĂ©e des plis ouverte. ça donne chaud au corps. sous emprisme de cette substance c'est la mort. ces cristaux de meth tue. c'est un pacte avec le diable.
Author: AhnizTech | Date: 2025-10-16 18:35:04
Blog N° 12
Title: SQLiteonline
Content:
SQLiteonline
Author: General Disclaimers | Date: 2025-10-16 16:09:20
Blog N° 11
Title: PATCH a post
Content:
// PATCH a post when you just want to update one parameter
app.patch("/posts/:id", (req, res) => {
const post = posts.find((p) => p.id === parseInt(req.params.id));
if (!post) return res.status(404).json({ message: "Post not found" });
if (req.body.title) post.title = req.body.title;
if (req.body.content) post.content = req.body.content;
if (req.body.author) post.author = req.body.author;
res.json(post);
});
Author: Hanifi Khelaf | Date: 2025-10-15 14:13:11
Blog N° 10
Title: GET HTTP
Content:
//Get a random joke
app.get("/random", (req, res) => {
const randomIndex = Math.floor(Math.random() * jokes.length);
res.json(jokes[randomIndex]);
});

//Get a specific joke
app.get("/jokes/:id", (req, res) => {
const id = parseInt(req.params.id);
const foundJoke = jokes.find((joke) => joke.id === id);
res.json(foundJoke);
});

//Filter jokes by type
app.get("/filter", (req, res) => {
const type = req.query.type;
const filteredActivities = jokes.filter((joke) => joke.jokeType === type);
res.json(filteredActivities);
});
Author: Khelaf Hanifi | Date: 2025-10-15 13:47:48
Blog N° 9
Title: How to properly close a port
Content:
nc localhost portNumber
Author: AhnizDigital | Date: 2025-10-15 13:14:39
Blog N° 8
Title: Own-API
Content:

import express from "express";

import bodyParser from "body-parser";



const app = express();

const port = 3000;

const masterKey = "4VGP2DN-6EWM4SJ-N6FGRHV-Z3PR3TT";



app.use(bodyParser.urlencoded({ extended: true }));


//Get a random joke

app.get("/random", (req, res) => {

const randomIndex = Math.floor(Math.random() * jokes.length);

res.json(jokes[randomIndex]);

});



//Get a specific joke

app.get("/jokes/:id", (req, res) => {

const id = parseInt(req.params.id);

const foundJoke = jokes.find((joke) => joke.id === id);

res.json(foundJoke);

});



//Filter jokes by type

app.get("/filter", (req, res) => {

const type = req.query.type;

const filteredActivities = jokes.filter((joke) => joke.jokeType === type);

res.json(filteredActivities);

});

Author: Hanifi Khelaf | Date: 2025-10-15 13:01:55
Blog N° 7
Title: process
Content:
compliance
Author: AhnizTech | Date: 2025-10-15 12:59:20
Blog N° 6
Title: Array.prototype.forEach()
Content:
const array = ["a", "b", "c"];

array.forEach((element) => console.log(element));

// Expected output: "a"
// Expected output: "b"
// Expected output: "c"
Author: AhnizDigital | Date: 2025-10-15 12:59:10
Blog N° 5
Title: Package.json
Content:
{
"name": "6.1-blog-api-project",
"version": "1.0.0",
"description": "",
"main": "index.js",
"type": "module",
"scripts": {
"test": "echo "Error: no test specified" && exit 1"
},
"keywords": [],
"author": "Hanifi Khelaf",
"license": "ISC",
"dependencies": {
"axios": "^1.4.0",
"body-parser": "^1.20.2",
"ejs": "^3.1.9",
"express": "^4.18.2"
}
}
Author: Hanifi khelaf | Date: 2025-10-15 11:28:35
Blog N° 4
Title: Accounting
Content:
Norme IFRS.
Balance sheet.
Income statement.
Accounting ledger.
Author: Touaddi | Date: 2025-10-15 10:08:34
Blog N° 3
Title: Data persistence
Content:
Now there's a whole bunch of different types of databases, but the main types that you'll hear about is SQL Database and a NoSQL type Database.
SQL stands for Structured Query Language.
Author: Hanifi Khelaf | Date: 2025-10-14 23:00:19
Blog N° 2
Title: What is Axios?
Content:
Axios is a promise-based HTTP Client for node.js and the browser. It is isomorphic (= it can run in the browser and node.js with the same codebase). On the server-side it uses the native node.js http module, while on the client (browser) it uses XMLHttpRequest.
Author: AhnizTech | Date: 2025-10-14 19:59:50
Blog N° 1
Title: AI on modern business
Content:
AI is eating the world.
Author: Hanifi Khelaf | Date: 2025-10-14 16:07:22

Thank you for your insightful blog post.

410 Visitors | Articles online: 36