Wednesday, March 13, 2024

WordPress website Migration & Restore using All-In-One-WP-Migration

Copy cPanel to cPanel internal server Migration

cp /home/Source-cPanel-username/public_html/wp-content/ai1wm-backups/your-backup-file-name.wpress /home/Target-cPanel-username/public_html/wp-content/ai1wm-backups


 Copy cPanel to cPanel Different server Migration


1. cd /home/Target-cPanel-username/public_html/wp-content/ai1wm-backups

2. wget use-source-url-https-link


All in One WP Migration Download

Sunday, March 10, 2024

Rebuild BCD in Windows using CMD


  1. Boot your computer into Advanced Recovery Mode
  2. Launch Command Prompt available under Advanced Options.
  3. To rebuild the BCD or Boot Configuration Data file use the command – bootrec /rebuildbcd
  4. It will scan for other operating systems and let you select the OS’s you want to add to BCD

To set boot record manually:

bcdboot c:\windows /s c:

Friday, February 16, 2024

Increment the cell in Vlookup when dragging horizontally in Excel

Excel VLOOKUP with Dynamic Column Reference:

=VLOOKUP($B16,$B$4:$D$13,COLUMNS($B4:B4)+1,0)

=VLOOKUP($B16,$B$4:$D$13,COLUMNS($B4:C4)+1,0)

=VLOOKUP(A53,'Tab(4Y-R)'!A24:AU157,COLUMNS('Tab(4Y-R)'!A24:A24)+1,FALSE())
=VLOOKUP(A53,'Tab(4Y-R)'!A24:AU157,ROWS('Tab(4Y-R)'!A24:A24)+1,FALSE())
=ROWS(B$4:B4)

Monday, January 22, 2024

How to Install and Use PHP Composer on CentOS 7

 sudo yum install php-cli php-zip wget unzip

php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"

HASH="$(wget -q -O - https://composer.github.io/installer.sig)"

php -r "if (hash_file('SHA384', 'composer-setup.php') === '$HASH') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;"

sudo php composer-setup.php --install-dir=/usr/local/bin --filename=composer


composer



Wednesday, November 22, 2023

The file GeoLite2-Country.mmdb does not exist or is not readable laravel

 Composer

From the command line run:

$ composer require torann/geoip

Laravel

Once installed you need to register the service provider with the application. Open up config/app.php and find the providers key.

'providers' => [

    \Torann\GeoIP\GeoIPServiceProvider::class,

]

This package also comes with an optional facade, which provides an easy way to call the the class. Open up config/app.php and find the aliases key.

'aliases' => [

    'GeoIP' => \Torann\GeoIP\Facades\GeoIP::class,

];

Publish the configurations

Run this on the command line from the root of your project:

php artisan vendor:publish --provider="Torann\GeoIP\GeoIPServiceProvider" --tag=config

A configuration file will be publish to config/geoip.php.

Configuration

Quick breakdown of the two main options in the configuration file. To find out more simple open the config/geoip.php file.

Service Configuration

To simplify and keep things clean, all third party composer packages, that are needed for a service, are installed separately.

For further configuration options checkout the services page.

Caching Configuration

GeoIP uses Laravel's default caching to store queried IP locations. This is done to reduce the number of calls made to the selected service, as some of them are rate limited.

Options:

  • all all location are cached
  • some cache only the requesting user
  • none caching is completely disable

Extract Domain from email in Excel or Google sheet

  =TEXTAFTER( A2 , "@") or, =MID(A1, FIND("@", A1) + 1, LEN(A1) - FIND("@", A1))