Git Product home page Git Product logo

istisharytalk's Introduction

IstisharyTalk

IstisharyTalk is a simple chat application that reads messages from a JSON file and displays them on a web page, automatically refreshing every second to show the latest messages.

image

Prerequisites

  • PHP (tested with PHP 7.4+)
  • A web server (e.g., Apache) with PHP support, such as XAMPP for local development
  • Web browser

Installation

  1. Clone the repository or download the ZIP file:

    git clone https://github.com/ademchaoua/IstisharyTalk.git
    cd IstisharyTalk
  2. Set up the project directories and files:

    Ensure the directory structure matches the one shown above.

  3. Configure the Web Server:

    If using XAMPP, place the project folder inside the htdocs directory (e.g., C:\xampp\htdocs\IstisharyTalk).

  4. Create or ensure the existence of msgs.json:

    In the database directory, create a msgs.json file if it doesn't exist and initialize it with an empty array:

    []

Permissions

Ensure that the database directory and the msgs.json file are writable by the web server.

Running the Application

  1. Start your web server (e.g., XAMPP):

    • Open the XAMPP control panel.
    • Start the Apache server.
  2. Access the application in your web browser:

    Navigate to http://localhost/IstisharyTalk/.

Login & Register

  1. Login:

    Users can log in by entering their credentials on the login page. The application checks the provided information against registered users stored in the system.

    image

  2. Register:

    New users can register by filling out the registration form. Their details are saved for future logins, enabling them to access the chat application.

    image

Using JSON as a Database

IstisharyTalk utilizes JSON files to store user credentials and chat messages. This approach provides a straightforward and lightweight solution for data storage.

  • User Credentials:

    User email addresses and hashed passwords are stored in users.json. Each entry in this file contains the following structure:

    [
      {
          "email": "[email protected]",
          "password": "hashed_password"
      }
    ]
  • User Information:

    User email addresses, first names, and last names are stored in userinfo.json. Each entry in this file contains the following structure:

    [
      {
          "email": "[email protected]",
          "first_name": "John",
          "last_name": "Doe"
      }
    ]

These JSON files serve as the backend database for user authentication and identification within IstisharyTalk.

License

This project is licensed under the MIT License - see the LICENSE file for details.

istisharytalk's People

Contributors

ademchaoua avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.