Thumbnail images not showing - laravel

i will be glad if anyone can help.
code line
OUTPUT

Have you ran php artisan storage:link? This is usually what does it for me.
Laravel 5 - How to access image uploaded in storage within View?

Related

New images not showing since upgrade to laravel 9

Please help me. I upgraded from laravel 7 to 9
Previous images displays but newly uploaded images are not. Images are saved correctly in the app/public/uploads and generated link is i.e my-domain-name.com/uploads/0000/1/2022/12/06/img-x-150 is correct. When link is entered on browser it aborts to 404 error page. I have read articles that suggest I cleared the cache, delete the storage link folder in app/public and run:
php artisan storage:link
Which I have done with no success.

Laravel: Uploaded image not showing

i keep getting 404 image not found when viewing the uploaded image on my project but the image is there. im using laravel's asset() helper to retrieve the image. the url in chrome shows http://127.0.0.1:8000/images/dU8oaVTAwQyTor86jvDtdGKvE7H3MYkHZuUG60gH.png and ive already done php artisan storage:link. any help is greatly appreciated.
You shouldn't use the asset helper for this, the url generated is wrong.
As you use the public storage, the url is supposed to be like this :
http://127.0.0.1:8000/storage/images/dU8oaVTAwQyTor86jvDtdGKvE7H3MYkHZuUG60gH.png
but aren't you supposed to access the image through the public folder if you do php artisan storage:link

My site doesnt output laravel page...What shoud i do?

On browser, typing localhost/spa1/public or spa1.test doesn't output the laravel. I've been stuck and cant even proceed to starting my project because of this. I really need help!!
The output supposedly :
enter image description here
The app key is :
APP_KEY=base64:lEpLqsi9GOqaz6eyu5VaTft0UOfj7u+A4LAie6LEJoc=
I'm using xampp on windows
My problem is y it doesnt output the Laravel page like the Google one?
In your terminal, you should start the server.
php artisan serve
This will create a home URL like localhost:8000 and read index.php file in the public folder.
BTW, the image you share is Laravel's default home page. If you look at welcome.balde.php file, you can see the same content there. So your app is running. But it's not a good idea to display your app without artisan serve.
Your code is fine, and this is how the home page looks like in Laravel 8. Because the home page you're talking about was in Laravel 7 & below. And from Laravel 8 onwards, the default home page of Laravel 8 is updated and looks like the one you're getting right now.

Laravel- Dompdf Maximum execution time of 60 seconds exceeded

Here is error when i convert pdf, it's not working since i run my laravel project by "php artisan serve --port=1000". But if i run my laravel project with xampp. it's alright. I don't know why?. Give me explaination and repairs . Thank you
Symfony \ Component \ Debug \ Exception \ FatalErrorException (E_UNKNOWN)
Maximum execution time of 60 seconds exceeded
The laravel - dompdf does not work well with php artisan serve. You should use XAMPP or another HTTP server you like.
Increase Your time limit in your controller file.Below variable to increase your time limit.
set_time_limit(300);
For me, there were two main issues.
Using images directly: I was using images with storage_path() so, I first convert image to base64 and pass it to the blade view.
Using external CSS: I was using bootstrap as external CSS and as we don't need whole bootstrap CSS, I just copy required CSS from bootstrap and place in internally with <style>..</style>
These steps make the PDF generation process very fast.
What I found was referencing to assets via asset() helper in the PDF view was throwing timeout exceeded error, I changed it to public_path() and it started working fine.
Possible causes:
linking to external CSS - you're better off writing your css between style tags in the same file as your html
using blade templating syntax e.g. #sections #roles, etc
linking to external images
Complex table structures/layouts
...from personal experience
use public_path for your external files for exe href="{{public_path('style.css')}}"
I had the same problem and narrowed it down to linking to an image in my blade file. When I embedded the image instead as per this SO answer, it no longer timed out.
dompdf does not work on
php artisan server
You should go through xampp server.
It solved my problem

Laravel 5.4 image won't upload

This is my first time working with Laravel 5.4 or any Laravel for that matter. I migrated a perfectly good working website to a new host. Now when I go to upload an image from admin or a user account the image won't upload. I get the whoops! error.
I have fixed all the broken links I can find, but I can't find where to go to fix the image won't upload issue.
Any help with this is greatly appreciated.
Thanks.

Resources