View more context



hi all. Is it possible to configure public/assets to be a different folder name, e.g. public/mycustomfolder ?


No, ASSETS_DIR is a hard-coded constant in silverstripe/framework

  1. if (!defined('ASSETS_DIR')) {
  2. define('ASSETS_DIR', 'assets');
  3. }

Actually you might be able to set it as an environment variable in your .env. No idea if anything will break though 😅


You could define it before it's initialised, e.g. in your _config.php?

Ken Sander

Working in my Mac dev enviroment with MAMP and PHP 7. OSX ships with php 5.4 so I was faking the php version in Silverstripe’s composer file with platform config — <;

That all worked fine but tonight upgrading some sites to 4.4.4 and getting the error:

PHP Parse error: syntax error, unexpected 'class' (T_CLASS), expecting identifier (T_STRING) or variable (T_VARIABLE) or '{' or '$' i in VendorPlugin.php when I run composer update

I updated composer as well, so not sure if it’s something with that.

Don’t really want to install PHP 7 and update path for mac CLI version as it’s not needed as MAMP handles all that.

Show 2 attachment(s)  
Config - Composer

A Dependency Manager for PHP  
Config - Composer

A Dependency Manager for PHP

Hide attachment content

@Ken Sander then you're choosing to use an end of life PHP version, where support over 3 years ago.