Search
 
SCRIPT & CODE EXAMPLE
 

PHP

alias to change php version on ubuntu

  alias setphp="sudo update-alternatives --config php;sudo update-alternatives --config phar; update-alternatives --config phar.phar; a2dismod php*.*;systemctl restart apache2"

  Put the above alias in the

  sudo nano ~/.bashrc
  
  #After the above command just run this command
  
  a2enmod php<Your Desired Version> # like, a2enmod php7.4
  
  Now you can run command "setphp" from your terminal.
Comment

PREVIOUS NEXT
Code Example
Php :: casts laravel 
Php :: laravel wrong timestamp 
Php :: sort an array in php manually 
Php :: laravel santum 
Php :: array_merge in php 
Php :: api symfony 4 @ApiResource 
Php :: php string literal 
Php :: xampp php 5.6 download 64 bit 
Php :: extract text before last space php 
Php :: laravel route multiple middleware 
Php :: wp_customize image 
Php :: php require_once 
Php :: array_chunk in php 
Php :: keep line breaks in textarea 
Php :: Laravel - Resize image size using Laravel image class 
Php :: session value not removed php 
Php :: Predefined Constants php 
Php :: orderby total sales woocommerce 
Php :: laravel check if collection has value 
Php :: preg_split 
Php :: php value in array200 
Php :: remove time from date in carbon 
Php :: download npm package 
Php :: laravel store blob image into database 
Php :: laravel migration table softdeletes 
Php :: class name laravel 
Php :: compare two datetime php 
Php :: hex2bin (PHP 5 = 5.4.0, PHP 7, PHP 8) hex2bin — Decodes a hexadecimally encoded binary string 
Php :: Woocommerce Changing the Entry Title of the Custom Endpoint 
Php :: silverstripe image upload field 
ADD CONTENT
Topic
Content
Source link
Name
2+2 =