Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

image not loading up #243

Open
ghost opened this issue Aug 28, 2018 · 1 comment
Open

image not loading up #243

ghost opened this issue Aug 28, 2018 · 1 comment

Comments

@ghost
Copy link

ghost commented Aug 28, 2018

Ok, i am trying to achieve this library in my localhost environment and i cant seem to find where the problem is.

Path is ok, image exists on it.

See following code for server config.

$server = ServerFactory::create([
            'response' => new LaravelResponseFactory(app('request')),
            'source' => $source,
            //'cache' => new Filesystem(new Adapter('../storage/app/cache/')),
            'cache' => $cache,
            'cache_path_prefix' => '.cache',
            'base_url' => 'transform-img',
        ]);

now i use this

return $server->getImageResponse($path, request()->all());

it does not give any error.

when i dd() this, i get this response.

StreamedResponse {#1151 ▼
  #callback: Closure {#1177 ▶}
  #streamed: false
  -headersSent: false
  +headers: ResponseHeaderBag {#1176 ▶}
  #content: null
  #version: "1.0"
  #statusCode: 200
  #statusText: "OK"
  #charset: null
}

as statusCode shows 200 and there is no error for file not found, still it does not load any image but shows a placeholder on browser when i navigate.

What can be the issue. if i try to replace image name with any other random string i get error for image not found. so this means it does find the image. thou it fails to render the image.

I have googled, searched here, could not find any problem similar as mine.

@ghost
Copy link
Author

ghost commented Aug 31, 2018

question also been asked on stackoverflow in detail.
Looking for feedback.
https://stackoverflow.com/questions/52058772/glide-library-image-not-loading-up?noredirect=1#comment91070703_52058772

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

0 participants