barryvdh / laravel-dompdf

A DOMPDF Wrapper for Laravel
MIT License
6.56k stars 963 forks source link

Public image not showing Laravel 10 #1058

Open matiassemelman opened 1 week ago

matiassemelman commented 1 week ago

Hello there, I'm using Laravel 10.10, and package 2.1.

I have my logo on public/ folder, just there. This is my function: private function generateLogo() { return "<img src='{{public_path('./pathful-logo') }}' alt='pathful-logo' class='logo' />"; }

I used public_path(), base_path(), with and without {{ }}.

GANONTHA commented 5 days ago

I am facing the same issue but with Laravel 11.x.x

parallels999 commented 1 day ago

did you try with asset()?

Also https://github.com/barryvdh/laravel-dompdf/issues/1059#issuecomment-2218671789