Home > Backend Development > PHP Tutorial > Secure database passwords in PHP

Secure database passwords in PHP

WBOY
Release: 2016-06-23 13:15:47
Original
801 people have browsed it

Method 1 - modify apache conf or .htaccess

    <files db.php>    order allow,deny    deny from all    </files>
Copy after login

Method 2 - Store them in a file outside web root.

e.g: include('../private/db.php')
Copy after login

Better approach is Method 1 + 2  :) 

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template