This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.

gtf21
gtf21

I don't have a database configured, and frankly don't need one for now at least. When using the demo theme, there's no problem, and the theme works fine without a configured database. When I switch to my currently-under-development theme, however, I get the following error:

SQLSTATE[HY000] [2002] No such file or directory

Caused by no database being configured.

  1. Why does the demo theme work without a database, yet my (pretty close to empty) theme not work?
  2. How do I turn off the database requirement?
ruslan6
ruslan6

Do you have any plugins installed?

gtf21
gtf21

@ruslan6: nope, this is a clean installation of October, and I've just created a new theme with a default layout, theme.yaml, composer.json and that's pretty much it.

(Well, the pre-installed october/demo plugin is installed, but that works without the DB, since the demo theme operates without a DB)

axomat
axomat

I think you need to give more information here because as your question implies this should not happen if you are just using a simple theme. So we do not have anything to go on to guess what the problem might be. What about supplying some of your settings in cms.php for example or app or database...

gtf21
gtf21

@axomat I'm not sure it does require more information. Let me clarify:

  • Clean installation of OctoberCMS with no database configured. The only thing that's changed is the application encryption key.
  • October demo theme and demo plugin exist as per a clean installation.

In this case I can see the October demo page when serving with php artisan serve, it all works fine.

Now, if I create a new theme, with a single layout which only has a bare-bones html structure and a single page, and switch to that theme, then I get the "no database" problem.

Anyway, I think I know what the problem is. The url for the page I was using was not configured. Unfortunately I'm too far down the development line to reliably go back and test this hypothesis but I imagine that it's the problem.

1-5 of 5

You cannot edit posts or make replies: the forum has moved to talk.octobercms.com.