I've found that if you change anything in the mysite/_config.php file, it permanently disables the whole silverstripe installation. I see other people have encountered this as well. This is a SERIOUS flaw that the silverstripe team should address. I've spent an entire day trying to find a fix but the only solution is a clean insall. Arrrrrrrgggggghhhhhhhh!!!
We've moved the forum!
Please use forum.silverstripe.org for any new questions
(announcement).
The forum archive will stick around, but will be read only.
You can also use our Slack channel
or StackOverflow to ask for help.
Check out our community overview for more options to contribute.
- Previous 10 entries
- 1
- Page 22(current)
- 3
- Next 10 entries
ANYthing? I find that hard to believe.
If you input the incorrect database info or mistype your project name, or theme name, then yeah I can see how that might cause some headaches and break the site.
I've found that if you change anything in the mysite/_config.php file, it permanently disables the whole silverstripe installation
To expand on what Ryan said, It shouldn't 'disable' anything. Make sure you put whatever you want to add at the bottom of the file (rather than the right top) as this can mess with some includes and if you have a ?> then it should be *before* this.
Make sure you have devmode on (see http://doc.silverstripe.org/debugging#dev_mode) and display_errors set to on (in your php.ini file) so you can see the error message while you're developing.
I only added one line at the end of my mysite/_config.php file and it again completely disabled everything!!!! Please help!
My _config.php file looks like this:
<?php
global $project;
$project = 'mysite';
global $database;
$database = '';
require_once('conf/ConfigureFromEnv.php');
MySQLDatabase::set_connection_charset('utf8');
// This line set's the current theme. More themes can be
// downloaded from http://www.silverstripe.org/themes/
SSViewer::set_theme('blackcandy');
// enable nested URLs for this site (e.g. page/sub-page/)
SiteTree::enable_nested_urls();
HtmlEditorConfig::get('cms')->setOption('extended_valid_elements', "img[class|src|alt|title|hspace|vspace|width|height|align|onmouseover|onmouseout|name|
usemap|style],iframe[src|n");
P.s. I tried enabling dev mode by adding Director::set_environment_type("dev"); at the end of my mysite/_config.php file but it also disables the cms and website.
I just keep getting the same stupid error: "The page isn't redirecting properly Firefox has detected that the server is redirecting the request for this address in a way that will never complete. This problem can sometimes be caused by disabling or refusing to accept
cookies."
P.p.s. I don't have access to the php.ini file as I'm working on a company's remote server.
It's working now, Hallelujah! This is what my mysite/_config.php looks like now:
<?php
global $project;
$project = 'mysite';
global $databaseConfig;
$databaseConfig = array(
"type" => "MySQLDatabase",
"server" => "localhost",
"username" => "xxxxxxxxxx",
"password" => "xxxxx",
"database" => "xxxxxxxxx",
);
require_once('conf/ConfigureFromEnv.php');
MySQLDatabase::set_connection_charset('utf8');
// This line set's the current theme. More themes can be
// downloaded from http://www.silverstripe.org/themes/
SSViewer::set_theme('blackcandy');
// enable nested URLs for this site (e.g. page/sub-page/)
SiteTree::enable_nested_urls();
//Director::set_environment_type('dev');
HtmlEditorConfig::get('cms')->setOption('extended_valid_elements', "img[class|src|alt|title|hspace|vspace|width|height|align|onmouseover|onmouseout|name|usemap|style],iframe[src|n");
It looks like the database config was the problem. It seems this part of the file is not configured automatically with the silverstripe install. Hope someone else finds this useful.
Lol....
If you ran the installer, it prevents you from continuing if the database fields aren't filled out properly. This was most likely human error. ;-)
I recently upgraded to 2.4.1, now I can't change the theme. Also, I did away with the ecommerce, payment & payment test modules however when I run dev/build it seems the tables associated with them are still in the database and the siteconfig table doesn't get updated with the mysite/config.php file. The only way I've found to change the theme is to edit the siteconfig table.
Would appreciate any thoughts.
Thanks,
Bob
- Previous 10 entries
- 1
- Page 22(current)
- 3
- Next 10 entries