Tag Archives: server

Restrict Access to Addon Domains

I run several websites on a single hosting plan. While some web developers do this to save money, I did this to save time. When you have all your hosted sites under one cPanel account(or in the same HTTP folder), it is easy to manage them. One problem you need to resolve is that add-on domain databases can be access through the primary domain. It can be fixed by adding a code to our good old .htaccess file in the sub-domain directory that host the files for the primary domain. The .htaccess file in each and every directory of the site must be edited(not the admin folders of CMSes) to include this code. Continue reading Restrict Access to Addon Domains

HTTP Status Code Definitions Explained

I ran in to into Error 500 issue about a week ago as soon as I tried to edit the .htaccess file on the server. I was blindsided because I had no clue what Error 500 stand for and the hosting service support team was useless because they told me that my name servers are out of order. After 24 hours wait time for DNS propagation, the site was still off line. So I decided to do my own little investigation. What I found was that Error 500 is caused by a programming error I made on the .htaccess file! I went to Continue reading HTTP Status Code Definitions Explained

Removing www from your URL

I finally decided to shut down my home based server for HTTP use for good. Why? With all the school work, I don’t have time to fix issues with the system. It comes with an added benefit of having a site that will be up 99.99%(according to the hosting provider’s uptime guarantee.) unless I make a coding error.

Anyway, while I was transferring data from self hosted server to the new hosting provider, I ran into few issues. One would be the transfer of data from the wordpress self host system to the paid professional service. I am still working on database issues such as my massive collection of multiple choice questions database for University of Calgary courses. Continue reading Removing www from your URL

Website migration and future of the site

Last week was super busy because I got the flu on top of exams and papers as usual. Each year around February to March I get the seasonal flu. I also had to write the Geochemistry midterm II, which is crucial for my success in the geology program. In the midst of my anxiety over the exams and the upcoming draft paper on the analysis paper for the Science 311, I decided to migrate all my data, exception to the Science site, from general PHP database with no CMS (Content Management System) to completely WordPress(WP) based system. I didn’t have to do much other than copying and pasting the data from old files since WP module has been installed and running on my server for the last few months. The old pages are still slowly being phased out. I will keep the old pages until Google decided to take them down from their indexed pages. With this migration, as the site admin my work load has been cut down significantly. The process of adding new information, pages, data, media, modifying existing data, layout, etc is much easier and faster with WP CMS. Since I am still working my degree, I may not update the site often, but I will do my best to come up with new information for the readers. Continue reading Website migration and future of the site

PHP based password protected access point

I found a PHP based script that will protect data from the general public. This is done using a simple PHP script that will terminate the page data from processing in HTTP request if a correct credential is not entered. The key part of this script is that it can be saved in any folder on the server regardless of the folder access is public or private. The script can be used to protect any web page using the PHP’s native data loading mechanism. I have no idea how secure the PHP script now protecting the secure science area. That’s where detailed user records comes in handy because in an event of a hack or a flooding, I can monitor the situation and close down all lose ends of the system. Continue reading PHP based password protected access point