Thursday, 20 April 2017

Disable access to add on domain through main domain

To send all traffic through the www URL for your Addon domain, the code will follow this format:

RewriteEngine On
RewriteCond %{HTTP_HOST} !^www.addondomain\.com [NC]
RewriteRule ^(.*)$$1 [R=301,L]

In your case, it would be:

RewriteEngine On
RewriteCond %{HTTP_HOST} !^\.com [NC]
RewriteRule ^(.*)$$1 [R=301,L]

To send all traffic through the non-www version of your Addon domain's URL, the code will follow this format:

RewriteEngine On
RewriteCond %{HTTP_HOST} !^addondomain\.com [NC]
RewriteRule ^(.*)$$1 [R=301,L]

In your case, it would be:

RewriteEngine On
RewriteCond %{HTTP_HOST} !^professionaldu\.com [NC]
RewriteRule ^(.*)$$1 [R=301,L]

Sunday, 17 April 2016

AWS - Stopping MYSQL from crashing

AWS - Stopping MYSQL from crashing

$ sudo dd if=/dev/zero of=/swapfile bs=1M count=1024
$ sudo mkswap /swapfile 
$ sudo chmod 600 /swapfile 
$ sudo swapon /swapfile 
$ sudo vim /etc/fstab

Add this line to fstab:swap   /swapfile     swap     defaults   0   0

Restart all the mysql and httpd server

Wednesday, 23 March 2016

Download Windows 7, 8.1 or 10 ISO Images Direct From Microsoft

Download Windows 7, 8.1 or 10 ISO Images Direct From Microsoft - [Thanks to]
It doesn’t matter what version of Windows you have, the best way to get your system working at its full speed and as issue free as possible is with a clean install of the operating system. Many small things can go wrong with your system over time which eventually will degrade performance and cause stability issues. Even with Windows 10 it’s recommended to clean install after upgrading so you are not transferring any problems from your old Windows install onto your new one.
Although it’s easy to get hold of a Windows 10 ISO image, burn it to DVD or write to USB and do a clean install, it’s becoming increasingly difficult to source official install media for older operating systems like Windows 7. Of course there are many unofficial sources like torrent sites but most of the best seeded files will have been cracked, tampered with or altered in some way, and it’s more difficult to verify safety and stability Using a trusted source is always much more preferable.
unofficial windows 7 torrent downloads
The best way to guarantee you are getting a clean and untouched Windows ISO image is going direct to the source, which is Microsoft themselves. It used to be easy to download Windows 7 ISO images until they were all removed from Digital River after sales of Windows 7 were discontinued. Microsoft doesn’t even want ordinary consumers to download a Windows 10 ISO direct anymore and instead pushes you to use the Media Creation Tool.

Thankfully there are ways around these obstacles and it’s possible to download Windows 7, Windows 8.1 and Windows 10 ISO images directly from Microsoft’s own servers, whether it’s through an officially recommended method or a workaround. Here we show you how to download the ISO you need so Windows can be installed cleanly and safely now or in the future.

Things To Know About Windows ISO Images And Reinstalling

  • Your Windows license only allows you to reinstall the edition of Windows that you have a license for. If you have Windows 7 Home Premium or Windows 10 Home for example, you must install that same operating system again. Trying to install an Ultimate or Pro edition over a Home edition will not work and activation will fail.
  • You can switch between 32-bit and 64-bit as long as the Windows edition is the same. For example you can replace Windows 7 Home Premium 32-bit with Home Premium 64-bit.
  • You do need a legal Windows license or the new install will be in trial mode. Windows 7 users will have a product key sticker. Windows 8./8.1 or 10 users will either have a separate key if Windows was purchased as a standalone product or the key will be embedded in the system BIOS and used automatically on reinstall if your computer is from a manufacturer such as Dell or Lenovo etc. If you upgraded to Windows 10 for free the license is tied to the computer hardware and will reactivate automatically on reinstall without entering a key.
  • If you are using Windows 7 with a computer purchased from a manufacturer and cannot read the product key on the sticker, it’s still possible to reinstall and activate without it. Read our article on backing up and restoring the Windows 7 license for help on what to do.

Download A Windows 10 ISO Image

There’s a couple of ways in which you can download a Windows 10 ISO. One is the Microsoft Media Creation Tool which allows you to download a Windows ISO file, upgrade to Windows directly or download the installation files onto flash drive so you can install from USB.

Download A Windows 10 ISO With The Media Creation Tool

1. Download the Windows 10 Media Creation Tool  and run it. Accept the license agreement, select “create installation media for another PC” and click Next.
2. The language, version and architecture type will be chosen that best matches the operating system you are running the tool on. To change these untick the recommended options box and chose what you want from the drop down menus. Click Next when done.
select windows 10 iso download options
The “Windows 10” option in the Edition menu will include Home and Pro versions, so if you also choose Both in the Architecture menu you’ll get an all in one ISO image with 32-bit and 64-bit versions of Windows 10 Home and Pro on the same disk.
3. Select “ISO file” to download an ISO image file and click Next. You’ll then be asked to supply a save location and filename. The files will then start to download.
Once complete you can open the DVD burner directly or click Finish and create the install media later. An all in one image with both 32-bit and 64-bit editions included will not fit on a single layer DVDR and you’ll have to use either a USB flash drive or dual layer DVDR.

Download A Windows 10 ISO From The Microsoft Website

This second method is quicker because you don’t need to use the Media Creation Tool but you cannot use it to download an image that includes both 32-bit and 64-bit versions on the same disk.
1. Visit the Microsoft Tech Bench webpage  for Windows 10. In the Select edition drop down choose the version of Windows 10 you want. Most people will need “Windows 10” which includes both Home and Pro editions. The N edition does not include Windows Media Player while KN is the same but for Korean users. Click Confirm.
2. Choose the language for the Windows ISO image and click Confirm.
windows 10 techbench edition language
3. Download buttons will now appear, one for a 32-bit download and one for a 64-bit download. The download link will only be valid for 24 hours after which you will need to go through the process again to get another valid link.
download windows 10 x86 or x64
Once downloaded you can burn the image to DVDwrite it to USB or store the file for later use.

Download A Windows 8.1 ISO Image

There’s still a lot of users around that have Windows 8.1 installed and they might want to keep hold of it and not upgrade to Windows 10. After all, Windows 8.1 is supported until 2023.

Download Windows 8.1 With The Media Creation Tool

Windows 8.1 also has its own Media Creation Tool although this one has less options than the Windows 10 version.
1. Download the Windows 8.1 Media Creation Tool  and run it. The first window offers the language, edition and architecture download options. Select from the drop down menus and clickNext.
windows 8 media creation tool
This tool offers Windows 8.1 and 8.1 Pro as separate downloads as well as 32-bit and 64-bit versions. The N versions are mainly intended for European markets and have media features missing like Windows Media Player.
2. Choose “ISO file” and click Next. A file requester will ask for the save location and filename, after supplying that the download will begin.
The ISO images for windows 8,1 are from late 2014 and include the major autumn update There is another way to download a Windows 8.1 ISO which is discussed below.

Download A Windows 7 SP1 ISO Image

Ever since Microsoft removed the Windows 7 ISOs from Digital River it’s been more difficult to find a clean and untouched image. The last official Windows 7 ISO is from 2011 which includes Service Pack 1 and and a minor KB2534111 hotfix  that fixed an install bug. There will be hundreds of updates after installation so creating an integrated ISO is worth considering.

The Microsoft Windows 7 Disc Images Page

The one official method left available requires you to enter your Windows 7 product key before you can download the image file.
1. Visit the Windows 7 Disc Images page  at Microsoft.
2. Enter your 25 character product key into the box and click Verify. If the key is accepted you will be able to download a Windows 7 ISO that corresponds to the license key you entered. Select the required language and a 32-bit or 64-bit version then download the file.
enter windows 7 product key
Important Note: This page has a massive problem because it only accepts retail license keys which you get only when purchasing a full boxed copy of Windows 7. If your computer is pre built from a manufacturer such as Dell or HP your key will be of the OEM type which cannot be used, the same also applies to volume licenses and system builder OEM versions. This restriction excludes most Windows 7 users from downloading an ISO image from the only official source available.

Download Windows 7/8.1 From The Windows 10 Download Page

The Russian release leak group WZor created a hack that allows you to download official Windows 7 and 8.1 ISO images from the Windows 10 download page. The hack involves injecting custom Javascript code into the page which unlocks further downloads besides the Windows 10 defaults.
We are using Google Chrome browser although the procedure is similar in Firefox, Internet Explorer, Edge and other browsers that have a Developer Tools panel.
1. Visit the Windows 10 Tech Bench page . To directly reach the Console tab in your browser press Ctrl+Shift+J for Chrome or Ctrl+Shift+K for Firefox. For Internet Explorer, Edge and other browsers useF12 to open the Developer Tools panel and click on the Console tab.
2. Download the Javascript text file , open it in Notepad and copy the text, then paste it (Ctrl+V) into the console of your browser and press Enter. Firefox users who have never pasted script into the console before will receive a warning message about pasting custom code, type “allow pasting” into the console, delete it when the message disappears and continue to paste the code from the text file.
enter javascript to download page
3. If you click on the Select edition drop down on the page it will now be populated with Windows 7, Windows 8.1 and also other Windows 10 download options.
select Windows edition downloads
4. Simply select the version you want, click Confirm, choose the language, click Confirm again and then download the required 32-bit or 64-bit version from the link.
download windows 7 from tech bench page
The original WZor script is much larger and includes N editions, Korean N and Chinese editions, Education versions and also commercial OEM versions. As those are unlikely to be of use we have modified the script above to include just the versions most users will want. You can download the full Wzor script  if you want one of those versions which has been left out.

Download A Windows 7 Or 8.1 ISO Without JavaScript

After studying the WZor script we found an easy way to quickly download an ISO without resorting to copying and pasting javascript code. Each Windows version has a download value which is parsed from the drop down when Confirm is clicked, by just injecting the required value into the page you can quickly download the version you want from Microsoft’s servers. Here’s how:
1. Visit the Tech Bench page  and in the Select edition drop down choose “Windows 10”.
2. Right click on the drop down and click Inspect. In Firefox this will be Inspect Element but Internet Explorer 11 and Edge cannot right click on the drop down so you will have to inspect the page first and find the HTML code in step 3 manually.
inspect windows 10 drop down
3. The line “” will be highlighted in the Developer Tools panel, click on the arrow to expand the code and you will see the Windows 10 entry currently has a value of “109” (this changes as newer Windows 10 versions are added).
windows 10 download value
4. Double click on the number and enter a value for the version of Windows you want from the list below.
value=’28’ Windows 7 Starter SP1
value=’2′ Windows 7 Home Basic SP1
value=’6′ Windows 7 Home Premium SP1
value=’4′ Windows 7 Professional SP1
value=’8′ Windows 7 Ultimate SP1
value=’48’ Windows 8.1 and Pro Single Language (Autumn 2014 update)
value=’52’ Windows 8.1 and Pro (Autumn 2014 update)
value=’79’ Windows 10 Home and Pro th1
value=’82’ Windows 10 Single Language Home and Pro th1
value=’109′ Windows 10 Home and Pro (1511 th2 Feb 2016 update)
value=’116′ Windows 10 Single Language (1511 th2 Feb 2016 update)
enter required Windows download value
5, Click Confirm on the page, select the language and download links will appear for the version of Windows that corresponds to the entered value. Don’t worry the drop down still says Windows 10 as it’s just display text. Above we are entering a value of 4 to download Windows 7 Professional.
This method is quick and easy and only requires you to remember a couple of numbers such as 4 and 52 for Windows 7 Pro and Windows 8.1. The Windows 10 values could be useful in future if you specifically want to download the RTM th1 or 1511 th2 February 2016 update versions.
To demonstrate how to download the Windows ISOs using both the Javascript inject and inspect page methods, we’ve made a video to show you how easy the process is.
download windows ISO youtube video

Verify The SHA1 Checksum Of Your Windows ISO

Windows ISOs are at least 2.4GB in size so it’s a good idea to check that your ISO is 100% complete and not corrupt. You can do this by comparing the SHA1 checksum of the downloaded file with the official checksum from Microsoft. If they don’t match your file didn’t download properly.
Here we’ll check for Windows 7 and 8.1 checksums as Windows 10 ISOs are constantly updated with different names and the corresponding SHA1 hashes are different.
1. Visit the MSDN Subscriber Downloads page . In the search box type the operating system name, for Windows 8.1 type “Windows 8.1 with update” or for Windows 7 enter the name and append “with service pack 1”, e.g. “Windows 7 Home Premium with service pack 1”. Press Enter or Go.
msdn search for iso
Note you may be asked to enter your Microsoft account details while browsing these pages, make sure you have a Hotmail, Live or Outlook email username and password to hand.
2. Using the search method above filters out a lot of versions that are of no use. To narrow the results further select 32-bit or 64-bit in the Architecture section on the left. Languages other than English can also be selected here.
3. Ignore anything in the list of editions with Embedded, Enterprise, Education, VL, N or K in the name and find the version you want. Once you’ve found it click the Details link underneath and information for the ISO including its official SHA1 checksum will be displayed.
view iso sha1 checksum
4. If you don’t already have a checksum tool handy we have a list of 10 File Integrity checking toolsso you can download one, or alternatively use the 7-Zip archiver. Then verify the SHA1 from the downloaded Windows ISO matches the MSDN value.
verify windows iso checksum
For your convenience we’ve listed some MSDN English language SHA1 checksums for ISOs downloaded from the Windows Tech Bench page (not via the Media Creation Tool).
Windows 7 Starter SP1 32-bit
SHA1: E1653B111C4C6FD75B1BE8F9B4C9BCBB0B39B209
Windows 7 Home Basic SP1 32-bit
SHA1: 080EC1DE94B88B0F7E8D000690A4AAAA031E2719
Windows 7 Home Premium SP1 32-bit
SHA1: 6071B4553FCF0EA53D589A846B5AE76743DD68FC
Windows 7 Home Premium SP1 64-bit
SHA1: 6C9058389C1E2E5122B7C933275F963EDF1C07B9
Windows 7 Professional SP1 32-bit
SHA1: D89937DF3A9BC2EC1A1486195FD308CD3DADE928
Windows 7 Professional SP1 64-bit
SHA1: 0BCFC54019EA175B1EE51F6D2B207A3D14DD2B58
Windows 7 Ultimate SP1 32-bit
SHA1: 65FCE0F445D9BF7E78E43F17E441E08C63722657
Windows 7 Ultimate SP1 64-bit
SHA1: 36AE90DEFBAD9D9539E649B193AE573B77A71C83
Windows 8.1 and Pro (Autumn 2014 update) 32-bit
SHA1: C7FA828E01E98B601E0ACA8019F1CB223EB23223
Windows 8.1 and Pro (Autumn 2014 update) 64-bit
SHA1: A8B5DF0B0816280AE18017BC4B119C77B6C6EB79
Windows 10 Home and Pro th1 32-bit
Windows 10 Home and Pro th1 64-bit
SHA1: 60CCE9E9C6557335B4F7B18D02CFE2B438A8B3E2
Windows 10 Home and Pro (1511 th2 Feb 2016 update) 32-bit
SHA1: 1FA08DA60F335E8ED33E56FF64C8063C9033E094
Windows 10 Home and Pro (1511 th2 Feb 2016 update) 64-bit
SHA1: B57921DDF4672C101F312AA66DD481350035D7E9
Some versions of Windows don’t have a corresponding checksum at MSDN such as the 8.1 and 10 single language ISOs and Windows 7 Home Basic 64-bit.

Unlocking Windows 7 Versions From A Single ISO

Many experienced users will know that each Windows 7 ISO contains all other available versions (except Enterprise). For instance the Home Premium ISO image also contains Starter, Home Basic, Professional and Ultimate but they are hidden from view. To unlock the extra versions all you need to do is remove the ei.cfg file from the image.
A simple way to do this is using a small program called the ei.cfg Removal Utility  which tells the UDF file system of the disk to ignore the file. This is a handy and quick method because opening the file, deleting it and then resaving the ISO is not required, the process here is near instantaneous. Below is a Home Premium 32-bit install disk with the ei.cfg removed.
windows 7 iso ei.cfg file removed
All you have to do is run the ei.cfg Removal Utility and locate the downloaded Windows 7 ISO, a small window will popup to say the file is removed, running it again will restore the ei.cfg. Using this method means you can save time and bandwidth and get all Windows 7 consumer editions by downloading a single Windows 7 ISO file instead of four or five

Tuesday, 24 November 2015

Speeding Up WordPress with Leverage Browser Caching

Add the following code into .htaccess file. 

Speeding Up WordPress with Leverage Browser Caching - Wanna Apps

Options All -Indexes
ExpiresActive on

# Your document html
ExpiresDefault "access plus 2 days"
# Media: images, video, audio
ExpiresByType image/gif "access plus 1 month"
ExpiresByType image/jpeg "access plus 1 month"
ExpiresByType image/png "access plus 1 month"

# CSS and JavaScript
ExpiresByType application/javascript "access plus 1 year"
ExpiresByType text/css "access plus 1 year"

Monday, 23 November 2015

How to Install SUPEE-6788 without SSH

October 27, 2015New Magento Security Patch (SUPEE-6788) – Install Immediately

Today, we are releasing a new patch (SUPEE-6788) and Community Edition to address 10+ security issues, including remote code execution and information leak vulnerabilities. This patch is unrelated to the Guruincsite malware issue. Be sure to test the patch in a development environment first, as it can affect extensions and customizations. Download the patch from the Community Edition Download page and learn more at


Warning: This patch may break some third-party modules that makes extensive use of custom variables and custom admin routes. Refer to community maintained list of all known incompatible extensions.

    Applying Magento patches via FTP/sFTP or FileManager / File Upload

    To apply patches in this way we simply replace changed files. This way can not be used blindly if you or your developers have changed any core Magento files (which is a big no-no, by the way). Such changes should be re-applied to patched files, or you loose these changes.
    The following files are changed by SUPEE-6788:

    To install the patch via FTP/File Upload
    • select patch bundle archive corresponding to your Magento version from the table below and unpack it
    • upload all files and folders to Magento root directory of your store, replacing all files
    • delete dev/tests/functional/.htaccess from your store (if exists)