0

I'm new to Craft CMS and would like to getting started, I searched for several hours now but I was not able to find an answer.

I downloaded and copied craft to my htdocs folder, created a database and changed the db access but when I open my page I get

Could not find your craft/ folder. Please ensure that $craftPath is set correctly in C:\xampp\htdocs\craft\public\index.php

I think I have to change the permission of that folder but I have no idea how to do this. Could you help me?

I didn't change any path, so it is correct and points to the right file but there is only one directory visible in C:\xampp\htdocs\craft\ in my browser

Edit: my Files looks like this
htdocs
-craft

--craft
---app
---config
---plugins
---storage
---templates
---.htaccess
---web.config

--public
---index.php

1
  • 1
    Can you maybe edit your original question and post a screenshot of what your folder structure looks like? i.e. where does the craft/app folder sit in relation to public/index.php? – Brad Bell Aug 24 '16 at 18:05
1

I believe the problem is that you've got craft within htdocs, so your web server is trying to run craft from the root, instead of where it should be, /public

To illustrate, this is where htdocs should be.

-craft

--craft
---app
---config
---plugins
---storage
---templates
---.htaccess
---web.config

--public <- htdocs
---index.php

I suggest, to test, that you change the httpd.conf to make apache run from the public folder rather than the pre-made htdocs folder xampp has given you. Go into the xampp config, click on httpd.conf and change the following lines:

enter image description here

DocumentRoot "your\path\to\htdocs\craft\public"

and

<Directory "your\path\to\htdocs\craft\public">

Restart your server, and you should be golden. On windows, you shouldn't have any permission issues with folders.

As an example, here is what my lines look like:

DocumentRoot "D:\Documents\work\bud\public"
<Directory "D:\Documents\work\bud\public">

I'd avoid just dumping the code in the pre-made htdocs folder provided and just route your httpd.conf to wherever your codebase is.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.