Device Detector

Device Detector is a utility class for identifying user browser, operating system, device type, and preferred language based on HTTP headers.

Tech Stack :
Device Detector

Device Detector

Device Detector is a utility class for identifying user browser, operating system, device type, and preferred language based on HTTP headers.

Features

  • Detects user's browser from the User-Agent header.
  • Identifies user's operating system from the User-Agent header.
  • Determines user's device type from the User-Agent header.
  • Retrieves user's preferred language from the Accept-Language header.

Installation & Usage

You can install the package via Composer:
  1. Include the Class in Your Laravel Project:

Get User Browser

Get User Operating System

Get User Device

Get User Preferred Language

Get All User Information

Methods

Retrieves the user's browser based on the
header.

Retrieves the user's operating system based on the
header.

Retrieves the user's device type based on the
header.

Retrieves the user's preferred language based on the
header.

Retrieves all user information (browser, OS, device, language) in an associative array.

Contributing

  1. Fork the repository.
  2. Create a new branch:
    .
  3. Make your changes and commit them:
    .
  4. Push to the branch:
    .
  5. Open a pull request.

License

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