Questions tagged [silverstripe-4]

Silverstripe 4 is the latest major version of the Silverstripe open source CMS and framework. Version 4.0.0 was released on 8th Nov 2017.

For a high level overview of changes to Silverstripe 4 from Silverstripe 3 and an upgrade guide, see the 4.0.0 changelog.

350 questions
2
votes
1 answer

SilverStripe GraphQL - error when querying types with descendants

I'm getting this error when trying to query a type and a descendant: "Fragment cannot be spread here as objects of type \"AppTestObject\" can never be of type \"AppTestChild\"." I set up a test install using recipe-core, admin, graphql, and…
Chris
  • 263
  • 3
  • 11
2
votes
2 answers

Silverstripe 4 change base url

where is it possible to change the baseURL on Silverstripe v4? Also after rewrite the base tag with http is set at the website. I would like to specify the baseURL itself, which will be applied to all pages (front site, admin). Thanks for every tip
Maximum
  • 61
  • 6
2
votes
1 answer

Silverstripe 4: Member Login and Redirect to specific page

I'd like to redirect Members who have successfully logged in to specific pages based on the group to which they belong. In the past I've been able to do this in SS3 with the following: CustomLoginForm.php: class CustomLoginForm extends…
pingu
  • 614
  • 1
  • 10
  • 23
2
votes
1 answer

How do I structure a Silverstripe envrionment for module development and testing?

I have scoured multiple blog posts on silverstripe.org and they all lead to videos/tutorials on module development that no longer exist because Silverstripe redid their entire "Lessons" section, which now focuses on how to modify an entire…
p0lar_bear
  • 2,203
  • 2
  • 21
  • 31
2
votes
1 answer

What is the alternative field for PhoneNumberField in silverstripe 4?

In silverstripe 4 can't find PhoneNumberField. Is there any alternative field for PhoneNumberField ? Thanks
2
votes
1 answer

Unable to add custom site config to Silverstripe 4

Im following the original docs but /dev/build is not generating the db fields and the form fields are not getting generated either. this is the value of my app/_config/app.yml --- Name: myproject --- SilverStripe\Core\Manifest\ModuleManifest: …
Gordon Freeman
  • 3,260
  • 1
  • 22
  • 42
2
votes
1 answer

Problems with class extending UserDefinedForm in Silverstripe 4

I've been stuck on this for a while now and I can't see where I'm going wrong. I've made a class that extends the UserDefinedForm so I can have a page that also has a UserDefinedForm on it. The form loads on the page, but it isn't as easy as just…
2
votes
1 answer

Silverstripe 4.1 public folder 404

I just started to try to make a theme in Silverstripe 4.1. The 4.1 version has a new feature where some of the resources are copied to the public folder (css files and image files). My problem is that the syncing seems to not work very well, I get…
user1716970
  • 743
  • 1
  • 8
  • 19
2
votes
2 answers

Silverstripe 4 error log

How can I log errors to file log in SilverStripe 4? I mean all errors causing 'Internal server error' info from SS In SilverStripe it was : SS_Log::add_writer(new SS_LogFileWriter('/var/log/silverstripe/errors.log'), SS_Log::ERR); Documentation…
user1479541
  • 21
  • 1
  • 2
2
votes
1 answer

Silverstripe 4 - Authenticator class not found

I would allow pre-generated users to log out from a SilverStripe 4 website front-end page, by using the default from. Logging out because log in works. The problem is that if a logged generic user tries to log out by clicking on a link like…
user7554217
2
votes
1 answer

inject basename of path into find exec command

I have a PHP command that works: php ~/.composer/vendor/bin/upgrade-code add-namespace "Vendor\Module\Finaldir" mymodule/finaldir --write -r -vvv" \; I would like to wrap this into a find -exec call (or similar) to do this recursively for folders.…
2
votes
1 answer

SilverStripe 4 - has_many relation on DataExtension

On SS 4.0.3 I'm just trying to make a relation between a SiteConfig extension and a DataObject. The DataExtension has a has_many relation pointing to a correspondent has_one in the DataObject. On /dev/build?flush=all the CMS throw me the following…
user7554217
2
votes
0 answers

Silverstripe form not showing error or success

I have the following form, public function ContactForm() { $fields = FieldList::create( TextField::create('Nombre', 'Tu nombre') ->setCustomValidationMessage('Por favor coloca tu nombre.') ); $actions =…
ramono
  • 462
  • 5
  • 16
2
votes
1 answer

Extending Image Class

Is there a way to extend the image class in Silverstripe 4 like this? class MyImage extends Image { public function generateRotateClockwise(GD $gd) { return $gd->rotate(90); } public function generateRotateCounterClockwise(GD…
Denis
  • 111
  • 1
  • 3
2
votes
1 answer

In SilverStripe 4, how to extend an existing method when there is no Extension Hook inside the original method?

I want to override 'loginForm' method in 'LoginHandler' class. I am trying to use the code given below for that. But it is not working. LoginHandlerExtension.php
ButterflyRay
  • 395
  • 2
  • 11