By webxtor01
Hello. I intend to use spaces as CDN. But I need it also to run a PHP script which would generate minimized js and css files on fly (if they do not exist yet). How can I achieve this?
Thanks
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Hi there @webxtor01,
I don’t think that this is possible. Spaces and other Object Storage solutions are meant to store static files like Images, Videos, CSS/HTML files and etc.
You can use Spaces with your PHP application and store your user uploads there for example, but you would still need an actual web server where you would run your PHP logic.
For more information make sure to check out this article here:
https://www.digitalocean.com/community/tutorials/object-storage-vs-block-storage-services
Hope that this helps! Regards, Bobby
PHP is generally white space insensitive, meaning that you can space out your code however you want to make your scripts more legible.
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.