© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•2y ago•
7 replies
ffffer.

FileUpload for Cloudflare Images

Hi,

I have a Forms\Components\FileUpload, and when editing, I want to show an image in a URL (not in the disk), something like:

Forms\Components\FileUpload::make('image')
                            ->formatStateUsing(function($record) { 
                                return 'https://picsum.photos/200'; 
                            })
Forms\Components\FileUpload::make('image')
                            ->formatStateUsing(function($record) { 
                                return 'https://picsum.photos/200'; 
                            })


(that code fails with error: foreach() argument must be of type array|object, string given)

How can I show the image in the URL?

Thanks
Filament banner
FilamentJoin
A powerful open source UI framework for Laravel • Build and ship admin panels & apps fast with Livewire
20,307Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

FileUpload Error Camera Images
FilamentFFilament / ❓┊help
13mo ago
Fill FileUpload with generated images
FilamentFFilament / ❓┊help
2y ago
Queue FileUpload(s) for large data (videos/images)
FilamentFFilament / ❓┊help
3y ago
Fileupload (medialibrary upload) : Generate TextInput for each images uploaded
FilamentFFilament / ❓┊help
2y ago