Skip to content
This repository was archived by the owner on Dec 11, 2020. It is now read-only.

Faker Image not working #1715

Closed
aronquiray opened this issue Jun 13, 2019 · 5 comments
Closed

Faker Image not working #1715

aronquiray opened this issue Jun 13, 2019 · 5 comments
Labels

Comments

@aronquiray
Copy link

http://lorempixel.com/ website is down. so no images is being downloaded or grab.

@localheinz
Copy link
Contributor

See #1712 and #1713.

@hokutoasari
Copy link

I use "picsum.photos" in my local env like following lines. But I think this is evil approach.

    public static function imageUrl($width = 640, $height = 480, $category = null, $randomize = true, $word = null, $gray = false)
    {
-         $baseUrl = "https://lorempixel.com/";
+        // $baseUrl = "https://lorempixel.com/";
+        $baseUrl = "https://picsum.photos/";
        $url = "{$width}/{$height}/";

and

            $fp = fopen($filepath, 'w');
            $ch = curl_init($url);
            curl_setopt($ch, CURLOPT_FILE, $fp);
+            curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
            $success = curl_exec($ch) && curl_getinfo($ch, CURLINFO_HTTP_CODE) === 200;

@t00nami
Copy link

t00nami commented Jun 17, 2019

https://lorempixel.com/ up again

@pimjansen
Copy link
Contributor

The follow location however is a good addition. Just replacing it is a bit too much where the service runs fine right?

@localheinz localheinz added the bug label Aug 23, 2019
@localheinz
Copy link
Contributor

Duplicate of #1712.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
5 participants