<!-- WP QUADS Content Ad Plugin v. 2.0.92 -->
<div class="quads-location quads-ad2522 " id="quads-ad2522" style="float:none;margin:0px 3px 3px 3px;padding:0px 0px 0px 0px;" data-lazydelay="0">

</div>

<p>These are instructions that demonstrate how to change WordPress to match your replaced or changed Public domain. as this occurs in case if you are already using WordPress and have it published on let&#8217;s say Domain1.com and then you transferred this domain to Domain2.com.</p>
<!-- WP QUADS Content Ad Plugin v. 2.0.92 -->
<div class="quads-location quads-ad2531 " id="quads-ad2531" style="float:none;margin:0px 3px 3px 3px;padding:0px 0px 0px 0px;" data-lazydelay="0">

</div>

<!-- WP QUADS Content Ad Plugin v. 2.0.92 -->
<div class="quads-location quads-ad2526 " id="quads-ad2526" style="float:none;margin:0px 3px 3px 3px;padding:0px 0px 0px 0px;" data-lazydelay="0">

</div>

<!-- WP QUADS Content Ad Plugin v. 2.0.92 -->
<div class="quads-location quads-ad2523 " id="quads-ad2523" style="float:none;margin:0px 3px 3px 3px;padding:0px 0px 0px 0px;" data-lazydelay="0">

</div>




<p>When you try to reach wordpress website from your new public domain. you might not reach it or wordpress might try to redirect you to your old domain1.com instead. </p>



<p>In order to fix this, we&#8217;ll have to use a tool called wp-cli which fixes this configuration problem. to do so please open your SSH shell or get in your UBuntu server and do the following. </p>



<ol class="wp-block-list"><li>sudo curl -O <a href="https://www.google.com/url?q=https%3A%2F%2Fraw.githubusercontent.com%2Fwp-cli%2Fbuilds%2Fgh-pages%2Fphar%2Fwp-cli.phar&;sa=D&;sntz=1&;usg=AFQjCNFiLT6qX91I3zjNx-GwJh6CkZGwbg" target="_blank" rel="noreferrer noopener">https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar</a></li></ol>



<figure class="wp-block-image"><a href="http://www.google.com/url?q=http%3A%2F%2Fwww.moh10ly.website%2Fwp-content%2Fuploads%2F2016%2F01%2Fclip_image001.png&;sa=D&;sntz=1&;usg=AFQjCNGfvqq9x19WZFs76mVoedYdD_eqJQ" target="_blank" rel="noreferrer noopener"><img src="https://lh5.googleusercontent.com/XRS48-KMIZxfrrRM108LXekxSJDAdZkJMIkQl9vTEB34XdNCk3vq7tXJMEnPr8NLpIZG8YUhKY95EGU3VtUXmjcB-aYHw2lMQsTDr-j7UwbsB47hqA=w673" alt="clip_image001"/></a> 

<!-- WP QUADS Content Ad Plugin v. 2.0.92 -->
<div class="quads-location quads-ad2525 " id="quads-ad2525" style="float:none;margin:0px 3px 3px 3px;padding:0px 0px 0px 0px;" data-lazydelay="0">

</div>
 
</figure>



<p> 2. From User@UbuntuServer:/var/www/html$ I will run the following command to make sure that the command is working</p>



<p>sudo php wp-cli.phar –info</p>



<figure class="wp-block-image"><a href="http://www.google.com/url?q=http%3A%2F%2Fwww.moh10ly.website%2Fwp-content%2Fuploads%2F2016%2F01%2Fclip_image002.png&;sa=D&;sntz=1&;usg=AFQjCNGbWIplBheAxFoLJwDMFnhfM2H12w" target="_blank" rel="noreferrer noopener"><img src="https://lh5.googleusercontent.com/oWM0lubUC2McfAjrT7-gFri41Rq-PW_0CM0CQ4NZ7dH3YoFfOfXbT-t7y1mIdXQSmi5oBr_GFx2lhONdXT_nIz6UTl38dUj5xmCUT4c_S5JCZxQ-K5Y=w673" alt="clip_image002"/></a></figure>



<p> 3. I’ll move the file to a new path and location so I can access it from anywhere using only the command WP.</p>



<p>First I will give the required permissions</p>



<p>moh10ly@Ubunut-Mohammed:/var/www/html$ sudo chmod +x wp-cli.phar</p>



<figure class="wp-block-image"><a href="http://www.google.com/url?q=http%3A%2F%2Fwww.moh10ly.website%2Fwp-content%2Fuploads%2F2016%2F01%2Fclip_image003.png&;sa=D&;sntz=1&;usg=AFQjCNHNYH0Ef8MIfXcwk-5SgdIBP5pKnQ" target="_blank" rel="noreferrer noopener"><img src="https://lh6.googleusercontent.com/b5GPridnBnciZpTfQAeHfLJtDxzN24ivYtyxn4RDPPmwjoK4M9kCPD3TeICP1VdBhLzz_JeOff8kc0bWyNuIQ1nRr98zGj1N9gKrJVNdg9g7as0wmtk=w572" alt="clip_image003"/></a></figure>



<p>Next I will move the file</p>
<!-- WP QUADS Content Ad Plugin v. 2.0.92 -->
<div class="quads-location quads-ad2524 " id="quads-ad2524" style="float:none;margin:0px 3px 3px 3px;padding:0px 0px 0px 0px;" data-lazydelay="0">

</div>




<p>sudo mv wp-cli.phar /usr//local/bin/wp</p>



<figure class="wp-block-image"><a href="http://www.google.com/url?q=http%3A%2F%2Fwww.moh10ly.website%2Fwp-content%2Fuploads%2F2016%2F01%2Fclip_image004.png&;sa=D&;sntz=1&;usg=AFQjCNFMEtqk_qUzgmRW37vvenwTSaqOAQ" target="_blank" rel="noreferrer noopener"><img src="https://lh4.googleusercontent.com/R3xRDS36HWV_DHUVAKEJBCQXe-vKqPNofGZDNUG9f0cU7JervjGgmLKrC-XRXlPQdlH7yAM=w673" alt="clip_image004"/></a></figure>



<p> 3. Check if the file is working properly after moving?</p>



<figure class="wp-block-image"><a href="http://www.google.com/url?q=http%3A%2F%2Fwww.moh10ly.website%2Fwp-content%2Fuploads%2F2016%2F01%2Fclip_image005.png&;sa=D&;sntz=1&;usg=AFQjCNFbrIFEF3VMX6RcOoVXjWmScfZg2w" target="_blank" rel="noreferrer noopener"><img src="https://lh6.googleusercontent.com/fEtMb5BV8tWBjYT9N7smP_WIefpuz_KcsqJ1-FGHhCyXBIJLFq2fQopWv79xAbnSSHWpTdOD9aS7srVlxxisaTwK9fJgMo6iJNvqDU8nf_6b7nQrBaQ=w472" alt="clip_image005"/></a></figure>



<p> 4. Final step is to change the domain of your wordpress site to a new domain.</p>



<p>My previous domain was <a href="http://www.google.com/url?q=http%3A%2F%2Fwww.mytechweb.ga%2F&;sa=D&;sntz=1&;usg=AFQjCNGTbmzu_ZE6_HoNCnvQ6mdqgxea6Q" target="_blank" rel="noreferrer noopener">www.mytechweb.ga</a> and now I changed it to <a href="http://www.google.com/url?q=http%3A%2F%2Fwww.moh10ly.website%2F&;sa=D&;sntz=1&;usg=AFQjCNH7KVtP4mv7OKybmFWpbPr-y1wxig" target="_blank" rel="noreferrer noopener">www.moh10ly.website</a></p>



<p>So I only used two commands to change the domain name to the new on</p>



<p> 5. moh10ly@Ubunut-Mohammed:/var/www/html$ wp option update home “<a href="http://www.google.com/url?q=http%3A%2F%2Fwww.moh10ly.website%2F&;sa=D&;sntz=1&;usg=AFQjCNH7KVtP4mv7OKybmFWpbPr-y1wxig" target="_blank" rel="noreferrer noopener">http://www.moh10ly.website</a>“</p>



<figure class="wp-block-image"><a href="http://www.google.com/url?q=http%3A%2F%2Fwww.moh10ly.website%2Fwp-content%2Fuploads%2F2016%2F01%2Fclip_image006.png&;sa=D&;sntz=1&;usg=AFQjCNFOlvbFA-7ezmIB5GCN3xa0S-ri1A" target="_blank" rel="noreferrer noopener"><img src="https://lh3.googleusercontent.com/VX_pqbfwMhHKk9R6zHWL6PjpvsLsfH0rbjrjnBLJmO_LkKOS32464_vQ-hphhEBRdQCu-60MNp2LK1Oz0_NcD1osw-QjHaLOrpdAo5w3heooEt2Uy622=w673" alt="clip_image006"/></a></figure>



<p> 6. moh10ly@Ubunut-Mohammed:/var/www/html$ wp option update siteurl “<a href="http://www.google.com/url?q=http%3A%2F%2Fwww.moh10ly.website%2F&;sa=D&;sntz=1&;usg=AFQjCNH7KVtP4mv7OKybmFWpbPr-y1wxig" target="_blank" rel="noreferrer noopener">http://www.moh10ly.website</a>“</p>



<figure class="wp-block-image"><a href="http://www.google.com/url?q=http%3A%2F%2Fwww.moh10ly.website%2Fwp-content%2Fuploads%2F2016%2F01%2Fclip_image007.png&;sa=D&;sntz=1&;usg=AFQjCNHRzY1uUQtVM__Z9FYSd1vjWd7Ykg" target="_blank" rel="noreferrer noopener"><img src="https://lh3.googleusercontent.com/I0AH5ueocTdqTMl50FzHzBbGkRCxLoEjdCQEOWOvWgFIWs4ODdR4KFh9wWcg8F-137Woo9RejZp6VDp8W3mbrkUonsYCsd1S3J-Ig4GhU-7v_up35UE=w673" alt="clip_image007"/></a></figure>



<p>Now I tested my website and it’s working perfectly…</p>
<!-- WP QUADS Content Ad Plugin v. 2.0.92 -->
<div class="quads-location quads-ad2529 " id="quads-ad2529" style="float:none;margin:0px 3px 3px 3px;padding:0px 0px 0px 0px;" data-lazydelay="0">

</div>




<p><a href="http://wp-cli.org/">http://wp-cli.org/</a></p>

<!-- WP QUADS Content Ad Plugin v. 2.0.92 -->
<div class="quads-location quads-ad2530 " id="quads-ad2530" style="float:none;margin:0px 3px 3px 3px;padding:0px 0px 0px 0px;" data-lazydelay="0">

</div>


Reset and manage your Active Directory users' Passwords Active Directory is one of the most…
Finding Exchange Database hidden mailboxes. Story:Maybe you have been in this situation before, trying to…
If you're using a Proxy server in your firewall or in your network and have…
Story:I got some clients that have reported some of their users being locked out and…
Delegate Permissions This is a code that I have wrote recently to check if an…
Story: I got a request from a client who constantly gets CVs and have to…