Menu
PHP BABA LOGO
  • Home
  • Interview Questions
    • PHP String Interview Question
    • PHP Array Interview Qutions
    • jQuery Interview Quetions
    • PHP Interviwe Question on php.ini file
    • htaccess File Interview Quetions
  • About
PHP BABA LOGO

Hide protected files in Laravel

Posted on September 21, 2020September 21, 2020

If you have multiple folder on live/development server for demo purpose and you want to hide .env and package file then use below code.

Create .htaccess file in root folder and past below code:

# Disable index view
Options -Indexes   # Hide a specific file
<Files “.*”>
    Order allow,deny
    Deny from all
</Files>  

<Files “package.*”>
    Order allow,deny
    Deny from all
</Files>

Categories

  • Docker
  • Git
  • Interview Questions
  • Laravel
  • Linux
  • php
  • Salesforce

Recent Posts

  • Batch Class in Salesforce
  • Platform Developer I Certification Maintenance (Winter ’24) Get Hands-on with Bind Variables in a SOQL Query
  • How to check Salesforce current release version
  • Salesforce Certification Coupons / Vouchers
  • Nested / Cascade query in SOQL

Recent Posts

  • Batch Class in Salesforce January 25, 2024
  • Platform Developer I Certification Maintenance (Winter ’24) Get Hands-on with Bind Variables in a SOQL Query December 19, 2023
  • How to check Salesforce current release version January 12, 2023
  • Salesforce Certification Coupons / Vouchers July 19, 2022
  • Nested / Cascade query in SOQL May 11, 2022
©2025 The Tech Paper | Powered by Abhinav Trivedi