Download the PHP package ilhamrisky/laravel-timezone-by-city without Composer

On this page you can find all versions of the php package ilhamrisky/laravel-timezone-by-city. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-timezone-by-city

Laravel Timezone by City

Latest Version on Packagist Total Downloads

Introduction

Laravel Get Timezone by City package provides a simple way to retrieve timezone information for cities around the world. It utilizes Carbon for date and time manipulation. This README will guide you on how to install and use the package in your Laravel project.

Data Source

The city data provided by this package is sourced from the GeoNames Gazetteer, available at GeoNames Gazetteer. GeoNames is a geographical database that covers all countries and contains over eleven million place names. As of the last update on February 16, 2024, it provides information for 146,892 cities worldwide.

Installation

Require this package with composer using the following command:

Usage

Import the namespace and instantiate the class in your Laravel controller or service

Example

Example 1: Check if a city exists in the dataset

Example 2: Get a list of all cities available in the dataset

Example 3: Get all data for a specific city

Example 4: Get the timezone for a specific city

Example 5: Get the UTC offset for a specific city

Example 6: Get the latitude and longitude for a specific city

Example 7: Get a list of cities based on their country code

Example 8: Get the current time in a specified city's timezone

Example 9: Get the city based on latitude and longitude coordinates

Example 10: Convert time between two cities' timezones

Example 11: Compare local time and city time

License (MIT License):

This package is released under the MIT License, which allows you to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the software. The only condition is that the above copyright notice and this permission notice shall be included in all copies or substantial portions of the software.

Feel free to contribute, create issues, or submit pull requests to enhance the functionality or fix any bugs.


All versions of laravel-timezone-by-city with dependencies

PHP Build Version
Package Version
Requires nesbot/carbon Version ^2.16
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package ilhamrisky/laravel-timezone-by-city contains the following files

Loading the files please wait ....