I was given a repository for Wordpress project, and need to run it locally, I'm using Mamp.

Where do I set the document root to? I don't see an index.php file in root of the repo, but there is a /wp-content folder, and of course a /themes folder which both have index.php files. I need to be able to view one of the themes in there.

Do I set the document root to /themes/myproject? Because that didn't seem to work either. I think it's because I need to create a certain database in phpmyadmin but how would I know what name its expecting?

PS. I also don't see a wp-config.php file anywhere in the repo. Can I just create my own, or would I need to know what the original settings were?

Thank you!!

  • Seems like the git repo was set to track the themes directory (you can inspect that reading .gitignore file) only. I'd download and install a fresh copy of WordPress and merge the themes folder into it,
    – Ismail
    Sep 20 '17 at 22:55

So your Git repository was initialized in the wrong place. If you have the initial files, you can go back there and try again making sure the git repo is in the actualy document root and make sure all of the files are tracked.

If you do not you can do a fresh install of Wordpress and copy the files in wp-content/uploads wp-content/themes and wp-content/plugins to the newly created wp-content directory.

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.