An .htaccess file contains directives that the web server will apply before page is displayed.
This means that a .htaccess file may allow or restrict access to files or directories, redirect to different resources or even change PHP-Configuration.
This is achieved by directives. A directive consists of a directive name and value.
Examples:
Before making any changes, it is important to consider how these rules are applied.
When a request is processed the web-server looks for a .htaccess file in the directory from which the content is served.
When found, any directives in this file are applied in their order within the file.
The server will then backtrack down each directory until it reaches the web-root (ie: /var/www) applying all rules from .htaccess files it finds along the way.
To get started you can create a plain-text file named .htaccess. Upload it to the document root, or a folder from which requests are served that you wish to modify.
(This can be also be done from within the ControlPanel=>File-Manager).
Each directive placed on a separate line. Examples of valid directives:
More Examples can be found in the Apache Web-Server Documentation located at: https://httpd.apache.org/docs/current/howto/htaccess.html