CWP PHP Selector

From version 0.9.8 all CWP servers have a CWP PHP Selector which can install all PHP versions with a single click.
Using CWP PHP selector you can use a different PHP version per folder or domain.

Usage instructions
In each folder where you want to run a different PHP version you only need to define it in the .htaccess file.

Example for file: /home/USERNAME/public_html/.htaccess

Use PHP 4.4
AddHandler application/x-httpd-php44 .php

Credits

Bypass the PowerShell Execution Policy

  • Use the “Bypass” Execution Policy Flag
This is a nice flag added by Microsoft that will bypass the execution policy when you’re executing scripts from a file. When this flag is used Microsoft states that “Nothing is blocked and there are no warnings or prompts”. This technique does not result in a configuration change or require writing to disk.
PowerShell.exe -ExecutionPolicy Bypass -File .runme.ps1
  • Use the “Unrestricted” Execution Policy Flag
This similar to the “Bypass” flag. However, when this flag is used Microsoft states that it “Loads all configuration files and runs all scripts. If you run an unsigned script that was downloaded from the Internet, you are prompted for permission before it runs.” This technique does not result in a configuration change or require writing to disk.
PowerShell.exe -ExecutionPolicy UnRestricted -File .runme.ps1
  • Use the “Remote-Signed” Execution Policy Flag
Create your script then follow the tutorial written by Carlos Perez to sign it. Finally,run it using the command below:
PowerShell.exe -ExecutionPolicy Remote-signed -File .runme.ps1

Transfer email accounts and messages between cPanel servers

You can transfer the email accounts and messages for a particular domain, from one cPanel server to another, by following the steps below.
 
Let's call the domain yourdomain.com for example. Make sure that you have yourdomain.com added as Parked or Addon in cPanel at the destination server.
 
Transferring the email accounts
Open your preferred FTP client, connect to the hosting account where the email accounts/messages currently are and navigate to the etc/ folder (located under /home/cpaneluser/etc/). There you will see a folder named yourdomain.com (the name of the domain you want to transfer the accounts/messages for). Download this folder anywhere to your local computer. This folder contains the email addresses (server configuration setup, encrypted passwords, etc.) associated with the corresponding domain.
 
Now connect with your FTP client to the server where you want to transfer the accounts. Navigate again to the etc/ folder and upload the previously downloaded yourdomain.com folder.
 
With this, the transfer of the email accounts is completed.
 
Before proceeding with the messages transfer you should remove or rename the downloaded yourdomain.com directory on your local computer.
 
Transferring the email messages
Simply repeat the process from step 1. This time, however, you should navigate to the mail/ folder (located under /home/cpaneluser/mail/). Download the directory called yourdomain.com to your local computer. This directory contains the messages for yourdomain.com. After that connect to the other account where you want to transfer the messages and upload the folder yourdomain.com to the mail/ directory.
 
With this, the transfer of your email accounts and messages is completed.
 
Now you can access cPanel -> Email accounts of the destination hosting account and check your transferred emails.
 
Your DNS provider will be able to assist you with the MX record changes, so you can point the mail-flow for yourdomain.com to the new hosting server.
 

Coloured equation in Impress

There is a color statement in Math that can be combined with a limited palette (RGB+CMYK+white) to set the hue of elements.
 
The basic form is:
 
color <keyword> { math element }
 
Valid <keyword> entries appear to be: red, green, blue, cyan, magenta, yellow, black, white. For example:
 
color red {sum from{color magenta {i=1}} to{color cyan{100}} color blue {i.}}
 

Disable APIPA (Automatic Private IP Addressing)

APIPA (Automatic Private IP Addressing) – Mechanism in a small network that clients will automatically allocated themselves an IP address in the range of 169.254.x.x if no DHCP server can be contacted.

 

It may be desirable to disable this and to do this perform the following:

 
  1. Start the registry editor (Regedit.exe)
  2. Move to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\Interfaces
  3. Select the required interface
  4. From the Edit menu select New – DWORD value
  5. Enter a name of IPAutoconfigurationEnabled and press Enter
  6. Double click the new value and set to 0. Click OK
  7. Close the registry editor

 

If you have multiple adapters and wish to disable for all just create and set HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\IPAutoconfigurationEnabled to 0.
 

Unprotect/Remove Excel Password

  1. Change the extension of you Excel file from .xlsx to .zip
  2. Extract these XML files outside the folder,they represent the worksheets in the Excel file.
    1. Location: xl -> worksheets -> *.xml
  3. Modified codes using simple “Notepad”.
    1. Open XML File & Delete  Excel v. 2007-10 “sheetProtection password=… />” v. 2013 – “sheetProtection algorithmName=…/>”
  4. Save & Close Xml File
  5. The modified XML file should be put again in the zipped file to replace the old XML files.
  6. Run File
 
 
 

Install Hyper-V on Windows 10

Install Hyper-V on Windows 10

Hyper-V can be enabled in many ways including using the Windows 10 control panel, PowerShell (my favorite) or using the Deployment Imaging Servicing and Management tool (DISM). This documents walks through each option.

Note: Hyper-V is built into Windows as an optional feature — there is no Hyper-V download.

Check Requirements

  • Windows 10 Enterprise, Pro, or Education
  • 64-bit Processor with Second Level Address Translation (SLAT).
  • CPU support for VM Monitor Mode Extension (VT-c on Intel CPUs).
  • Minimum of 4 GB memory.

The Hyper-V role cannot be installed on Windows 10 Home.

Upgrade from Windows 10 Home edition to Windows 10 Pro by opening up Settings > Update and Security > Activation.

For more information and troubleshooting, see Windows 10 Hyper-V System Requirements.

Enable Hyper-V using PowerShell

  1. Open a PowerShell console as Administrator.

  2. Run the following command:

PowerShell
Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V -All

If the command couldn't be found, make sure you're running PowerShell as Administrator.

When the installation has completed, reboot.

Enable Hyper-V with CMD and DISM

The Deployment Image Servicing and Management tool (DISM) helps configure Windows and Windows images. Among its many applications, DISM can enable Windows features while the operating system is running.

To enable the Hyper-V role using DISM:

  1. Open up a PowerShell or CMD session as Administrator.

  2. Type the following command:

PowerShell
DISM /Online /Enable-Feature /All /FeatureName:Microsoft-Hyper-V

Console window showing Hyper-V being enabled.

For more information about DISM, see the DISM Technical Reference.

Enable the Hyper-V role through Settings

  1. Right click on the Windows button and select ‘Apps and Features’.

  2. Select Programs and Features on the right under related settings.

  3. Select Turn Windows Features on or off.

  4. Select Hyper-V and click OK.

Windows programs and features dialogue box

When the installation has completed you are prompted to restart your computer.

Create a Virtual Machine with Hyper-V

Create a virtual machine and install its operating system.

We've been building new tools for creating virtual machines so the instructions have changed significantly over the past three releases.

Pick your operating system for the right set of instructions:

Let's get started.

Windows 10 Fall Creators Update

In Fall Creators Update, Quick Create expanded to include a virtual machine gallery that can be launched independently from Hyper-V Manager.

To create a new virtual machine in Fall Creators Update:

  1. Open Hyper-V Quick Create from the start menu.

    Quick Create Gallery in the Windows Start menu

  2. Select an operating system or choose your own by using a local installation source.

    Gallery view

    1. If you want to use your own image to create the virtual machine, select Local Installation Source.
    2. Select Change Installation SourceButton to use a local installation source
    3. Pick the .iso or .vhdx that you want to turn into a new virtual machine.
    4. If the image is a Linux image, deselect the Secure Boot option. Button to use a local installation source
  3. Select "Create Virtual Machine"

That's it! Quick Create will take care of the rest.

Windows 10 Creators Update

Screen shot of the quick create UI

  1. Open Hyper-V Manager from the start menu.

  2. In Hyper-V Manager, Find Quick Create in the right hand Actions menu.

  3. Customize your virtual machine.

    • (optional) Give the virtual machine a name.
    • Select the installation media for the virtual machine. You can install from a .iso or .vhdx file. If you are installing Windows in the virtual machine, you can enable Windows Secure Boot. Otherwise leave it unselected.
    • Set up network. If you have an existing virtual switch, you can select in the network dropdown. If you have no existing switch, you will see a button to set up an automatic network, which will automatically configure a virtual network.
  4. Click Connect to start your virtual machine. Don't worry about editing the settings, you can go back and change them any time.

    You may be prompted to ‘Press any key to boot from CD or DVD’. Go ahead and do so. As far as it knows, you're installing from a CD.

Congratulations, you have a new virtual machine. Now you're ready to install the operating system.

Your virtual machine should look something like this:

Virtual machine start screen

Note: Unless you're running a volume-licensed version of Windows, you need a separate license for Windows running inside a virtual machine. The virtual machine's operating system is independent of the host operating system.

 

Credits:

https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows/quick-start/enable-hyper-v
https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows/quick-start/quick-create-virtual-machine

VLC for openSUSE

VLC VideoLan client
VLC Repositories for openSUSE contains all the required libraries that are not shipped with original openSUSE. (VLC is also provided by Packman, do not add both repositories.)
 
Version: Tumbleweed http://download.videolan.org/pub/vlc/SuSE/Tumbleweed/
 
Version: Leap 15.0 http://download.videolan.org/pub/vlc/SuSE/Leap_15.0/
 
 
zypper dup:
 
After adding VLC repository be sure to switch system package to those in VLC as a mix of both can cause a variety of issues.
 
Version: both zypper dup –from SuSE –allow-vendor-change

 

Credits: https://en.opensuse.org/Additional_package_repositories#VLC_VideoLan_client

System file check to look for corrupt files.

Right click at Start button > click Command Prompt (Admin) > at the flashing prompt, copy/paste this…….
sfc /scannow

> press Enter.
It will take quite sometime.
When finished, it will give you one of the 3 reports……………(paraphrasing)
1. No integrity violation.
2. Found corrupt files and repair successful.
3. Found corrupt files but unable to repair.

If the report is #1, your solution lies elsewhere.
If the report is #2, check if your problems have been resolved.
If the report is #3, use this method…………….
In the same Command Prompt (Admin) windows, copy and paste this command………..

dism /online /cleanup-image /restorehealth

> press Enter.
Again it will take some time.

 

Credits