GithubHelp home page GithubHelp logo

dmitry-ivanov / dark-sky-api Goto Github PK

View Code? Open in Web Editor NEW
70.0 3.0 5.0 6.5 MB

PHP Library for the Dark Sky API.

License: MIT License

PHP 100.00%
php api dark-sky dark-sky-api darksky darksky-api laravel laravel-package weather forecast

dark-sky-api's Introduction

Hi, I'm Dmitry Ivanov! Nice to meet you! I'm a Software Engineer, Laravel Developer, Open-Source Developer, Problem Solver, and Constant Learner.

dark-sky-api's People

Contributors

dmitry-ivanov avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

dark-sky-api's Issues

Use a formatter on the forecastUrl() function for the round() lat/lng.

Versions:

  • Package Version: ^1.1
  • PHP Version: 7.3.6

Description:

Hey! :)
I got a problem using the library, my PHP locale information was set to fr_FR, and it's making the round() function replace the lat and lng dots with commas. That leads to broke the featured request with a 400 Poorly formatted request :

https://api.darksky.net/forecast/[KEY]/45,509,-73,588

Using the number_format function can fix this problem.

$latitude = number_format(round($parameters->getLatitude(), 3), 3);
$longitude = number_format(round($parameters->getLongitude(), 3), 3);

This is located in src/Http/Request/UrlGenerator.php.

Steps to reproduce:

setlocale(LC_NUMERIC, 'fr_FR'); before execute the forecast function.

Installation stand alone

Hi,

Sorry, I am not familiar with namespaces, normally use includes, but it does not matter what I do, I cannot get your class to work with our api key, can you help?

I want stand alone, could you suggest the correct folder structure to store, and how to call it?

Really really appreciated as your class looks the best type.

Regards

Rob

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.