Login
Simple Step To Edit .Php Files In Directadmin

Simple Step To Edit .Php Files In Directadmin

 

Here’s how to use the cPanel File Manager to edit the contents of any text-based files in your Linux Hosting account

 

  1. Go to your Abollyhost product page.
  2. Under Web Hosting, next to the Linux Hosting account you want to use, click Manage.
    click manage
  3. In the top left-hand corner of the account Dashboard, select File Manager.select file manager
  4. In the cPanel File Manager, use the directory tree to browse to the file you want to edit.
  5. Right-click the file and select Editfrom the popup menu.
  6. (Optional) Select any encoding options you want to use and then click Edit.
  7. Edit your file, and then click Save Changes.
  8. Click Close to go back to the main File Manager page.
How to Generate and Install SSL Certificate on Directadmin Control Panel

How to Generate and Install SSL Certificate on Directadmin Control Panel

SSL Secure Server

This section covers certificate installation requirements, how to use the server’s shared certificate, creating a self-signed certificate, and installing a purchased certificate. Any site that processes monetary transactions or takes in sensitive information (such as passwords) needs the protection of a SSL certificate.

Accessing SSL menu with DirectAdmin

To create SSL certificate, or to paste pre-generated certificate key, access “Account Manager” from Control Panel, then click “SSL Certificates” link.

ssl access
ssl access

Installing a Let’s Encrypt Certificate

Probably easiest way to install secure, free and browsers trusted certificate for your site is Let’s Encrpyt certificate, so we strongly recommend to use this method if you don’t want to buy certificate from trusted authorities.

Note: You must enable let’s encrpyt in DA to use it. If you don’t see “Let’s Encrpyt” section in SSL certificates menu, ask your admin to enable it. If you are admin, you can enable Let’s Encrpyt by following this guide.

To enable Let’s Encrypt, choose “Free & automatic certificate from Let’s Encrypt” radius.

Enter Common name and E-mail.

Note: do not use “www” or “http(s)://” in common name section.

Choose which Certificate Entries you want to secure. You can select maximum of 20.

Note: Always select yourdomain.com and www.yourdomain.com entries.

Press “Save” button. That’s it!

ssl lets encrypt certificate

Note: Do not forget to setup private_html as explained here. Also, you may need to wait few minutes for users to see your site as secured.

Installing a Purchased Certificate

A purchased certificate is the best form of security. Because the certificate is both secure and trusted, visitors will not receive a warning popup window when viewing a secure page.

Step 1: Generate a CSR

Make sure to click the radio button next to “Create A Certificate Request.”

Then, enter the information about your company.

The “Common Name” refers to the address of your site that will go on the SSL certificate.

ssl self signed certificate

Your site will be secure only at this address. In the above example, https://garys-host.com/anything would be valid, but nothttps://www.subdomain.garys-host.com.

When you are finished, click the “Save” button at the bottom of the screen. You will then see a page that looks like this:

Copy this text (including the “BEGIN/END CERTIFICATE REQUEST” sections) into a plain text editor such as Windows Notepad and save the file to your hard drive. You will need this CSR when you purchase a certificate.

Step 2: Purchase a Certificate

When purchasing a certificate, you will be asked about yourself or your company, your web site, and:

  • the CSR
  • the software that generated the CSR
  • your common name
The CSR

Simply paste the CSR given to you by the control panel, including the “BEGIN/END CERTIFICATE REQUEST” sections. There will be a text box in the order form to paste to. Please ensure the CSR is saved and pasted as plain text.

Software that Generated the CSR

Choose Apache-ModSSL(“OpenSSL”), or “Other” if you don’t see Apache-ModSSL in the list. Do not worry about making a mistake, as this information is collected for statistics purposes only.

Your Common Name

The “Common Name” refers to the address of your site that will go on the SSL certificate (see Step 1). Enter this address without the “http://” unless otherwise specified by the certificate seller.

Step 3: Install a Certificate

Select the radio button next to “Paste a pre-generated certificate and key.”

As you can see, the key is already inserted in the text box for you.

Paste the certificate immediately in “Certificate” box below it and click “Save.”

The domain’s certificate might be named domain.com.crt

ssl pre generated certificate

Step 4: Install the CA Root Certificate

In picure above you can see “CA Root Certificate” link. Click on the link and paste your CA Root Certificate in the textbox. Also, click “Use a CA Cert” box above. Then, click the “Save” button.

Important: Remember to check the “Use a CA Cert.” box.

Although the installation of a CA Root Certificate is not always required, you may find that your SSL certificate will not function properly without completion of this step.

The CA Certificate may sometimes be call the gd_bundle.crt, ca_bundle.crt, ca_cert, etc..

Note: Do not forget to setup private_html as explained here.

Using the Server’s Shared Certificate

One of the simplest ways to have a secure site is to use the server’s built-in self-generated certificate.

Make sure the radio button next the “User the server’s certificate” is selected, and click the “Save” button at the bottom of the screen.

ssl server

Understanding non-Trusted Certificates

Warning: Although non-Trusted certificates provide a high level of encryption, they are not always the best choice because they are self-generated instead of purchased from a trusted authority.

Because of this, visitors to your site may receive a warning popup window when they access a secure page. Therefore, we DO NOT recommend using this method.

ssl error

Creating a Self-Signed Certificate

An alternative to the self-generated shared server certificate is a personalized self-signed certificate.

Step 1: Click the radio buttons to select “Create your own self signed certificate.”

Step 2: Enter the information about yourself and your company.

A list of country codes is available here.

Step 3: Click the “Save” button at the bottom of the screen.

ssl self signed certificate

The Common Name is the exact web address the certificate is associated with. In the above example, https://garys-host.com/anything would be valid, but not https://www.subdomain.garys-host.com.

Understanding non-Trusted Certificates

Warning: Although non-Trusted certificates provide a high level of encryption, they are not always the best choice because they are self-generated instead of purchased from a trusted authority.

Because of this, visitors to your site may receive a warning popup window when they access a secure page. Therefore, we DO NOT recommend using this method.

ssl error

Uploading Files to your Secure Site

All secure files need to be uploaded to the /domains/domain.com/private_html directory. Easiest way to do this is to link private_html to public_html. To do that go to “Account Manager” icon in Control Panel and choose “Domain Setup” link (You can see pictures of path in page begin). Press private html setup link at the botton of page. Select “use symbolink link” radio and press “Save.”

private html setupr

Need more help?

Please contact us for more assistance,

Uploading Files With DirectAdmin’s File Manager

Uploading Files With DirectAdmin’s File Manager

Uploading with DirectAdmin File Manager is easy way to transfer files between your computer and server without any additional programs required.

  • 1. Sign into the control panel and click the “System Info&Files” icon.
  • 2. Select “File Manager” menu.
  • 3. Navigate to the directory where you want to upload files.
  • 4. Click the “Upload File” button at the bottom of the screen.

  • 5. After that, just Drag & Drop desired items from your computer to DirectAdmin, and press “Upload”.
  • 6. Note: Make sure the destination path above is correct. (path / start at your home directory).
connect with ftp

Uploading files with DirectAdmin’s File Manager is really simple and usefull. You can also change file’s permissions or even edit files from direct admin control panel.

DirectAdmin File Structure

Directory Structure

The organization of files into a hierarchy of folders is known as the directory structure. The directory structures is modeled after the hierarchical tree model. Let’s take a closer look at the DirectAdmin directory structure in detail.

 

Apache

/etc/httpd              – Apache

/etc/httpd/conf/         – Configuration files are stored in this directory

/etc/httpd/conf/ssl.crt/    – SSL certificates are stored here

/etc/httpd/conf/ssl.key/   – SSL certificate key stored here

/etc/httpd/conf/extra/    – Contains virtual hosts

/var/log/httpd/          – Apache log

/usr/local/etc/rc.d/httpd start/stop   – For Apache start or stop

 

DirectAdmin

/usr/local/directadmin              – DirectAdmin Installation directory

/usr/local/directadmin/scripts/        – Contains scripts

/var/log/directadmin/               – DirectAdmin log

/usr/local/directadmin/custombuilds   – Contains build scripts

/usr/local/directadmin/data/templates  – DirectAdmin templates

 

Mail

/var/spool/virtual/              – Mail directory

/etc/virtual                    – Email virtual

/etc/exim.conf                 – Configuration file

/var/log/exim/                 – Exim log

/etc/virtual/acrilicos.com         – Domain specific mail settings

/etc/virtual/acrilicos.com/aliases   – Email aliases

/etc/virtual/acrilicos.com/quota    – Email quota

/etc/virtual/acrilicos.com/passwd   – Email password

/usr/local/etc/rc.d/exim start/stop  – For Exim start or stop

 

Named(BIND)

/var/named/etc/namedb/named.conf  – Configuration file

/var/named                      – BIND directory

/etc/namedb/domain.db            – Database files

/usr/local/etc/rc.d/named start/stop   – For DNS start or stop

 

Database

/usr/local/directadmin/conf/mysql.conf   – MySQL password stored here

/etc/my.cnf                         – Configuration file

/usr/local/mysql/data/                – Database path

/var/lib/mysql/                      – MySQL log

/usr/local/etc/rc.d/mysqld start/stop     – MySQL start or stop

 

FTP

/etc/proftpd.conf                 – FTP configuration file

/etc/proftpd.passwd               – FTP password

/etc/proftpd.vhosts.conf            – FTP virtual hosts

/var/log/proftpd/                  – FTP log

/usr/local/etc/rc.d/proftpd start/stop  – FTP start or stop

 

SSHD

/etc/ssh/sshd_conf      – SSHD configuration file

/var/log/messages      – Log

 

If you need any further assistance please contact our support department.

Was this article helpful

How to enable LetsEncrypt on DirectAdmin

LetsEncrypt is a free SSL tool that lets you install a very basic free SSL Certificate with 1 click.  It supports multiple domains and sub-domains, and will auto-renew automatically before it expires after it’s ~90 day lifespan.

To enable this feature in DirectAdmin,

ensure you have DirectAdmin 1.50.1 or newer.

  1. If you’re running CentOS 6 or newer, it’s recommended to set DA to allow SNI. This will keep the setup simpler, especially when setting up SSL under an Admin account on the server IP (so it’s not installed globally)
  2. Enable the letsencrypt=1 option in the directadmin.conf
  3. Restart DirectAdmin:
    echo "action=directadmin&value=restart" >> 
    /usr/local/directadmin/data/task.queue; /usr/local/directadmin/dataskq d2000
  4. Add the /.well-known Alias:
    cd /usr/local/directadmin/custombuild
    ./build rewrite_confs
  5. Install the most recent version of the script:
    cd /usr/local/directadmin/custombuild
    ./build update
    ./build letsencrypt

Users should then be able to see the LetsEncrypt option in their ‘Enhanced’ skin via:

User Level -> SSL Certificates