There used to be Windows XP virtual machines on modern.ie. I still have a couple of copies around for testing. Unfortunately after XP going out of support, they were removed. But the copies used to be on Azure CDN (credit /u/JoshBrodieNZ. Seems like they recently removed them too.

To create.vmx file for Windows 7 use can use online vmx file builder (VMX file is Vmware virtual machine core configuration file and each virtual machine has its own.vmx file.) Enter Following information while using VMX builder. Display Name: Windows XP. Guest OS: Windows XP Professional Edition. Microsoft Windows Server 2003 Service Pack 2 (SP2) is a cumulative service pack that includes the latest updates and provides enhancements to security and stability. This service pack is available for Windows XP Professional, x64 Edition.

Vmx File Extension
There's still a way to get Windows XP 32-bit VMs from Microsoft (no 64-bit) through Windows XP mode. It contains a VHD (virtual hard disk) with a 32-bit Windows XP SP3.

Open Vmx Files
- Download Microsoft XP Mode from https://www.microsoft.com/en-us/download/details.aspx?id=8002.
- Using 7-zip or any other utility decompress the exe.
- Inside sources, there's another file called
xpm
. Decompress it too. With 7-zip, right click on it and select 'Extract to ... .' - One of the extracted files is
VirtualXPVHD
and around 1.2 GB. Rename it toVirtualXP.vhd
. - In VirtualBox (or any other virtualization software that supports importing VHDs), create a new Windows XP 32-bit VM and use this file as the hard disk. When you start the VM, it will start a Windows XP setup. My mouse did not work, but you can use shortcut keys to navigate the installer (e.g. Alt+N for Next).
- ???
- Profit.

For a step by step guide with pictures, check this post from howtogeek.com.