Website Process

1. You enter http://server.com into your browser’s address bar.

2. Your browser looks up the IP address for server.com.

3. Your browser issues a request to that address for the web server’s home page.

4. The request crosses the Internet and arrives at the server.com web server.

5. The web server, having received the request, fetches the home page from its hard disk.

5.1 Apache is the web server that processes requests and serves web assets and content via HTTP.

6. With the home page now in memory, the web server notices that it is a file incorporating PHP scripting and passes the page to the PHP interpreter.

6.1 PHP is the programming language that works with Apache to help create dynamic web content.

7. The PHP interpreter executes the PHP code.

8. Some of the PHP contains MySQL statements, which the PHP interpreter now passes to the MySQL database engine.

8.1 MySQL is the database that stores all your information in an easily queried format.

8.2 phpMyAdmin is a free and open source administration tool for MySQL

9. The MySQL database returns the results of the statements back to the PHP interpreter.

10. The PHP interpreter returns the results of the executed PHP code, along with the results from the MySQL database, to the web server.

11. The web server returns the page to the requesting client, which displays it.

Website Prerequisites

Website Host

Hosts website data (e.g. content files and domain name).

Fairly reliable provider, interServer

interServer

List of (currently) usable features:

  • VPS tab > gear button
    • 1 VPS Slice = 1 Core CPU, 1GB Memory, 25GB Disk Space and 25GB bandwidth
  • Name Servers for domain name: More > DNS Manager (DNS Servers)
  • Support

Experiences with it . . .

  • Account got instantly disabled when added credit card. You raised ticket requesting them to enable account.
  • You have to open ticket to ask them to enable SSL for you. 
  • For server migration, raise ticket requesting for InterServer Migration team to help (they go by first come first serve). 
    • Also provide them details of old server account(s) and the DirectAdmin details.

NOTE: Not ALL of what InterServer explains/claim is accurate so ensure to see/check/try for yourself first

Unreliable providers (based on experienced users’ feedback): 

  • vpsserver.com – unreliable customer support, blocks domain name without notice, and so on
  • Inmotion – can be slow, won’t backup your sites when they transfer server, and so on

Website (domain) Name Provider

Some reliable providers: NameSilo, NameCheap

Must update Name Servers (obtained from WEBSITE HOST)

NameSilo

Update NameServers:

  • Manage My Domains > Manage DNS for this domain button
  • Domain Manager > click domain > Domain Console (NameServers)

Website Management

Prerequisites:

  • Website Domain Manager

Reliable providers: cPanel, DirectAdmin

DirectAdmin

Can either install yourself or ask them to install for you for free. Asking them experience . . .

We need to open a ticket for installing the Directadmin
Which is performed by our Admin team

Once the directadmin installation has completed (notified From our admin via ticket /email)
We need to open another ticket with old host control panel login details to perform the migration
make sure that, you include the old host control panel login details in the migration ticket

DirectAdmin features…

Account Manager > Show All Users > 
Increase quota (e.g. E-mail Accounts to unlimited (under Email Manager)): Click on Username > Actions (top right blue button) > Modify User
Manage Database @ DirectAdmin: User Login > MySQL Management (not phpMyAdmin, you don’t have privilege for it)

Find out which database your domain/subdomain uses in the wp-config.php file located in the domain/subdomain folder
Install SSL (User > Account Manager > SSL certificate > Free & automatic certificate from Let’s Encrypt)

To install SSL, https://www.transip.eu/knowledgebase/entry/512-like-use-ssl-certificate-directadmin/
Access Files: 
Select & Login as User > System Info & Files > File Manager
Alternatively, log in through FTP
Then add your domain: Login to DirectAdmin > Access Level: User > Domain Setup > Add New > enter domain name > Create (DirectAdmin automatically creates (next to the other required settings) an email address for this user with the syntax ‘username@yourdomain.com’)

If you want to use IPv6, then an additional adjustment is required within DirectAdmin. Without this adjustment, visitors to your domain using IPv6 will see an ‘Apache is functioning normally’ message.

For IPv6, Access Level Admin > Server Manager: IP Management > check the IP addr. that you want linked to IPv6 > ?????? (details do not match, have to find guide from another source)

To add subdomain, {???? not done -> create a subdomain in your DNS records > click ‘Save’} > @DirectAdmin, Access Level User > Subdomain Management

Account Manager > Show All Users > click the user you want’s Username > click Login as <username> > Subdomains > Add Subdomain > click Create

To link multiple domains to one website, ref. https://www.transip.eu/knowledgebase/entry/655-directadmin-tutorial-series-domains-subdomains/
Adding subdomain:
Account Manager > Subdomain Management > Add Subdomain
Raise Disk Usage limit . . .
Account manager–> show All users —>Select user—> Modify—> Manually update

One way to increase website speed is to add the expires headers below to  to .htaccess located at public_html folder (access using FTP) . . .

# Expires headers
<IfModule mod_expires.c>
ExpiresActive on
ExpiresDefault "access plus 1 month"
# cache.appcache needs re-requests in FF 3.6 (thanks Remy ~Introducing HTML5)
ExpiresByType text/cache-manifest "access plus 0 seconds"
# Your document html
ExpiresByType text/html "access plus 0 seconds"
# Data
ExpiresByType text/xml "access plus 0 seconds"
ExpiresByType application/xml "access plus 0 seconds"
ExpiresByType application/json "access plus 0 seconds"
# Feed
ExpiresByType application/rss+xml "access plus 1 hour"
ExpiresByType application/atom+xml "access plus 1 hour"
# Favicon (cannot be renamed)
ExpiresByType image/x-icon "access plus 1 week"
# Media: images, video, audio
ExpiresByType image/gif "access plus 4 months"
ExpiresByType image/png "access plus 4 months"
ExpiresByType image/jpeg "access plus 4 months"
ExpiresByType image/webp "access plus 4 months"
ExpiresByType video/ogg "access plus 4 months"
ExpiresByType audio/ogg "access plus 4 months"
ExpiresByType video/mp4 "access plus 4 months"
ExpiresByType video/webm "access plus 4 months"
# HTC files (css3pie)
ExpiresByType text/x-component "access plus 1 month"
# Webfonts
ExpiresByType font/ttf "access plus 4 months"
ExpiresByType font/otf "access plus 4 months"
ExpiresByType font/woff "access plus 4 months"
ExpiresByType font/woff2 "access plus 4 months"
ExpiresByType image/svg+xml "access plus 1 month"
ExpiresByType application/vnd.ms-fontobject "access plus 1 month"
# CSS and JavaScript
ExpiresByType text/css "access plus 1 year"
ExpiresByType application/javascript "access plus 1 year"
</IfModule>

To manage website content, can use CMS (Content Management System) such as WordPress.

Website Backup
https://wordpress.org/support/article/backing-up-your-database/ @ Using phpMyAdmin # section (phpMyAdmin @ DirectAdmin after logging in to profile)
Copy Your website Files to Your Desktop using an FTP client

Backup site: Copy files through FTP
Backup database: phpMyAdmin > Databases tab > At left click database name > Click Export tab > Click Custom > (x)
Format: SQL
Tables: Select all the tables.
Output: 
select Save output to a file
Compression: None (If your database is very large, use a compression method)
Object creation options:
Check “Add DROP TABLE” (this can be useful for over-writing an existing database.)
Check “IF NOT EXISTS” (this prevents errors during restores if the tables are already there)

(x) > Click Go. The data will now be saved into your computer.


Delete database: phpMyAdmin > Databases tab > check database(s) > click Drop
Website Transfer


Transfer Websites For Addon Domain
————————–
Note: Need to download and zip file and database of website first

1). Reseller >> Create New User >> Fill up all details 
2). Click on the domain, go for Login as domain name
3). System Info >> File Manager >> Upload File then extract
4). Create DataBase >> Account >> MySQL Database >> Create New Database
5). Change Wp.config.php for database, username and password
6). Login phpMyAdmin, then import Database
7). Change Nameserver at domain registrar
8). Submit SSL >> Account Manager >> SSL certificate >> Go tab “Free & automatic certificate from Let’s Encrypt” , at Let’s Encrypt Certificate Entries, check the 3 entries for  domain, mail and www
Website Security
1. Don’t use “admin” as your username
2. Don’t use “wp_” as your database prefix.
3. Use a secure password
4. Keep WordPress, plugins and themes up to date
5. Use a security plugin:
https://en-ca.wordpress.org/plugins/better-wp-security/
https://en-ca.wordpress.org/plugins/all-in-one-wp-security-and-firewall/
https://en-ca.wordpress.org/plugins/wp-simple-firewall/

Reference

  1. Nixon, R. (2018). Learning PHP, MySQL & JavaScript: With jQuery, CSS & HTML5. Sebastopol, CA: OReilly Media.

--- :: Skyferia Tech's Related Posts :: ---