Posts marked with "Apache" in tags

Getting IP Address of Your Friend Through Chat

It’s awesome to get into the depth of the network, especially when it’s the internet. An IP address can get you to a person far away from your home. It will make you mind blown when you dig deeper into the internet network. As you may have read, netstat -an command gave you the IP address of user through Facebook chat. But, this works no more. But, there are still ways to do this.... [READ MORE]

Accessing /var/log Files in PHP

If you have tried to access a log file in /var/log using PHP in Linux, you will see the “Permission denied” error. This is because, Apache doesn’t have read permission on the log file. Let’s look at the user groups that have permission to access the log files : it’s root and the program which created the file. Suppose, let’s say the log file is “/var/log/squid/access.log”. That file’s group and owner will be “proxy” and others won’t even have the read permission on it except **root **ofcourse.... [READ MORE]

Installing Laravel In Sub Directory & Deny Access To It

Laravel is a PHP framework that reduces the work load of creating PHP applications. As it is a framework, there are limitations and some problems just like any other PHP program. Laravel framework has a “public” folder. The HTML files that are going to be displayed on Web Server will be from this folder. Since it is a sub directory of the framework, to access the real site, we would have to go to the following URL :... [READ MORE]

Prevent Directory Listing using HTACCESS

If you don’t want your site users to see your directory listing, you can do a simple trick in .htaccess file. Here is a screenshot of a directory listing on Apache Server : Now, to disable directory listing of all types of files, type in the following code in .htaccess : IndexIgnore * This will change the directory listing to this : The empty directory listing looks ugly. To make it beautiful, you can add an index page for all directory listings without adding each index files on each directory.... [READ MORE]

Creating a custom 404 Not Found page in Apache Server.

DEMO You might have seen a 404 page on different sites such as Google,Yahoo etc… You can make this on your website too if you are using Apache Server. The default 404 page will be like this : It’s just simple plain HTML 404 page and it’s ugly. To Change the default 404 page Do as below. Go to your site’s folder. Create a file named .htaccess (just .htaccess no name only file extension). Open the file and add the line.... [READ MORE]



Mastodon  Twitter

GitHub GitLab


Demos  Lab


This blog was once on WordPress. Now a static site. See source code on