silverstripe/silverstripe-installer

Fresh install not saving page content

Closed this issue · 8 comments

Hi, first time dealing with Silverstripe and having some problems with a fresh install.

I'm on MacOS and installed MAMP, and installed composer and ran the command composer create-project silverstripe/installer example

Originally navigated to htttp://localhost:8888/example and was given an error message that it was missing a .env
So I added this:

## Environment {#environment}
SS_ENVIRONMENT_TYPE="dev"

## Database {#database}
SS_DATABASE_CHOOSE_NAME="true"
SS_DATABASE_CLASS="MySQLDatabase"
SS_DATABASE_USERNAME="root"
SS_DATABASE_PASSWORD="root"
SS_DATABASE_SERVER="localhost"
SS_DEFAULT_ADMIN_USERNAME="admin"
SS_DEFAULT_ADMIN_PASSWORD="password"

And it redirected me to {app_url}/example/dev/build and it seems to have created a lot of files.
However, navigating to the homepage doesn't show the default page content that seems to appear in the tutorial videos.

The pages home, about, contact where autogenerated when I the site was build, and I can edit the home the titles, and even create pages, but it doesn't save the content of a page - It says "successfully saved" in the toast message, but then the content disappears.

My _config.php looks like this:

<?php

use SilverStripe\Security\PasswordValidator;
use SilverStripe\Security\Member;

// remove PasswordValidator for SilverStripe 5.0
$validator = PasswordValidator::create();
// Settings are registered via Injector configuration - see passwords.yml in framework
Member::set_password_validator($validator);

But this differs from the content that appears in the apps repo https://github.com/silverstripe/silverstripe-framework/blob/4/_config.php
(Not sure if this is expected or something is going wrong with my install)

In Chrome's console, when I try save I see the following error:

POST http://localhost:8888/example/admin/pages/edit/EditForm/2/ net::ERR_EMPTY_RESPONSE

Does anyone have any idea what might be wrong?

Hi there, can you try to set SS_BASE_URL=http://local host:8888/example in your .env and see if that helps?

@robbieaverill I added that to .env, and I tried restarting apache and also doing flushing, but same issue. Meta data saves just fine, but clicking save says it was successfully saved, the "save" button is reset (as if it saved) but the content disappears

Why was this issue marked as closed? :(

Thanks for trying that out. This issue is open, I just closed your duplicate.

Can you share the version you’ve installed please? composer show | grep silverstripe

Oh, sorry, must have been a github delay it looked closed 😅

❯ composer show | grep silverstripe
silverstripe-themes/simple            3.2.0   The SilverStripe simple theme (default SilverStripe 3 theme)
silverstripe/admin                    1.5.0   SilverStripe admin interface
silverstripe/asset-admin              1.5.0   Asset management for the SilverStripe CMS
silverstripe/assets                   1.5.0   SilverStripe Assets component
silverstripe/campaign-admin           1.5.0   SilverStripe campaign admin interface
silverstripe/cms                      4.5.0   The SilverStripe Content Management System
silverstripe/config                   1.0.18  SilverStripe configuration based on YAML and class statics
silverstripe/errorpage                1.5.0   ErrorPage component for SilverStripe CMS
silverstripe/framework                4.5.0   The SilverStripe framework
silverstripe/graphql                  3.2.0   GraphQL server for SilverStripe models and other data
silverstripe/recipe-cms               4.5.0   SilverStripe recipe for fully featured page and asset content editing
silverstripe/recipe-core              4.5.0   SilverStripe framework-only core recipe
silverstripe/recipe-plugin            1.3.0   Helper plugin to install SilverStripe recipes
silverstripe/reports                  4.5.0   Reports module for SilverStripe CMS
silverstripe/siteconfig               4.5.0   Site wide settings administration.
silverstripe/vendor-plugin            1.4.1   Allows vendor modules to expose directories to the webroot
silverstripe/versioned                1.5.0   SilverStripe Versioned component
silverstripe/versioned-admin          1.3.0   SilverStripe versioned admin interface

Hi @8bithero ,

I am coming here from stackoverflow. Please see my answer about this issue here https://stackoverflow.com/questions/59911265/silverstripe-not-saving-page-content/60047809#60047809

I checked all the files, but unfortunately this doesn't seem to be the case :(

@8bithero Is there any chance you'd be able to test this in a different environment? For example:

If it works in one of these other environments, this is likely an issue with MAMP, which we can't provide official support for. There are great community support options where you can get help including our forum, Stack Overflow (remember to tag as silverstripe) and even Slack.

If you manage to reproduce the same issue in a different environment, let us know.

closing due to lack of feedback