© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•3y ago•
10 replies
Darpan

Panel domain - CORS Issue - Spatie Media Library File Upload

When I use
$panel->domain('admin.example.test')
$panel->domain('admin.example.test')
I get following error

Access to fetch at 'https://example.test/storage/1/mWYF1pIRZoK9jwFPajd7FCdDN2kdua-metaYXV0aG9yLWJhbm5lci5qcGc=-.jpg' from origin 'https://admin.example.test' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.
Access to fetch at 'https://example.test/storage/1/mWYF1pIRZoK9jwFPajd7FCdDN2kdua-metaYXV0aG9yLWJhbm5lci5qcGc=-.jpg' from origin 'https://admin.example.test' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.


but it works when I remove
->domain()
->domain()
and use
->path()
->path()
.

How can I make it work?
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

Spatie Media File Upload Issue
FilamentFFilament / ❓┊help
2y ago
spatie media library file upload load file
FilamentFFilament / ❓┊help
2y ago
Spatie Media Library File Upload replacing every uploaded file
FilamentFFilament / ❓┊help
3y ago
Unique identifier for file upload (Spatie Media Library)? 🤷♂
FilamentFFilament / ❓┊help
2y ago