How to Use and Create Apache Handlers for File Types
Apache handlers are used to control what action Apache performs when encountering specific file types. By default, Apache is programmed to recognize and process certain file types with predetermined actions. If you want Apache to take a different action for a file type, you can create a custom handler. For instance, if you have server-side include files without a .shtml
extension, you can set up an Apache handler to treat these files accordingly.
What are Apache Handlers?
Apache handlers enable you to specify custom actions for different file types. For example, if you use a file type that needs a particular service to process it, such as files with server-side includes, you can configure Apache to handle those files. More details on Apache's handlers can be found in the official Apache documentation.
Creating an Apache Handler in cPanel
Follow these steps to set up an Apache handler in cPanel:
- Log in to your Bluehost Account Manager.
- Under Quick Links in Server Information, click on CPANEL.
- On the cPanel dashboard, locate Advanced click on Apache Handlers.
- In the first empty text box, enter the handler name you want to create.
- In the second text box, specify the file extension the handler should apply to.
- Click Add to save the handler.
- Click Go Back to return to the main cPanel menu.
Summary
Apache handlers allow you to customize how Apache processes different file types on your server. By setting up handlers, you can ensure that specific files are processed as required, helping you maintain optimal performance and functionality.
If you need further assistance, feel free to contact us via Chat or Phone:
- Chat Support - While on our website, you should see a CHAT bubble in the bottom right-hand corner of the page. Click anywhere on the bubble to begin a chat session.
- Phone Support -
- US: 888-401-4678
- International: +1 801-765-9400
You may also refer to our Knowledge Base articles to help answer common questions and guide you through various setup, configuration, and troubleshooting steps.