DEV Community

Cover image for PHP Phone Book

Posted on • Updated on • Originally published at

PHP Phone Book

This is my first public repository on GitHub.

Image description


UTC Timezone

username: admin
password: 123


  • 1.Clone or download: GitHub Repository
  • 2.Create a new MySQL database.
  • 3.Set your database information and your PROJECT_URL in config.php.
  • 4.Browse /setup to create the required tables and admin sign up.

    Ex. https://localhost/PHP-Phone-Book/setup/

  • 5.Remove /setup directory.

  • 6.Set media directory permission to 777.

    sudo chmod -R 777 media


  • HTTP Server: Apache
  • Programming language: PHP 8.2.4
  • Programming paradigm: OOP
  • Architectural patterns: MVC
  • Template engine: TWIG 3.0
  • Database: MySQL
  • Licensed under MIT

I used:

  • Multi language suppourt.
  • PDO & Prepared Statements MySQL Connection.
  • Errors handling method.
  • Singleton design patterns for some required classes.
  • Many options for configuration. config.php
  • Sorting and pagination of items.
  • Client and server side captcha for sign in form.

    Optional config: Google reCaptcha or Cloudflare Turnstile

  • Bootstrap and jQuery.


Add new language

  1. Create your language file in the lang folder.

Ex. fr.php or ar.php and develop similar to lang/fa.php.

  1. Add your new language for frontend pages.
<!-- Example: -->
<div class="changeLanguage">
     <button id="fr">Fr</button>
     <button id="en">En</button>
<!-- Look at: .changeLanguage click function on view/assets/js/app.js or backend.js  -->
Enter fullscreen mode Exit fullscreen mode

** Ready to develop for other pure PHP projects **

Connect with me:

Linkedin: ramoures


Top comments (2)

blossom profile image
Blossom Babs

This is such a fun project

cyberfiducia profile image

Well done. Just checked this out. Clean and simple.