0

I know this question may first appear to be a duplicate of others, but I'm asking this because I have WordPress installed in my /var/www/html directory. I was learning WordPress a couple of years ago before creating a website and never used it again.

Well, I'm creating a php project using PhpStorm and testing in my browser. I'm following a tutorial so I can configure my databse (phpmyadmin), and the instructor keeps going to his localhost, which displays the directory structure as seen here:

localhost directory structure

Since I have WordPress on my localhost, navigating to that takes me to my WordPress installation, which is not what I want to access.

I would rather ask this question on here before I potentially break my Apache configuration, so how can I access this project? Do I need to remove WordPress completely? It would be nice to keep it for future testing since I'm slowly getting into making plugins.

What are your suggestions? I can't really say much as far as "what have you tried?" since I don't know where to begin.

Running in Chrome within my PhpStorm IDE takes me to localhost:63342/projectName/respectivePhpFileName.php, but I can't access it outside of the IDE yet.

Any help would be appreciated.

2
  • Just move your Wordpress outside your htdocs folder...I think he is using something like XAMPP so in that way is very easy to do it, because the folder without an index will be detected as a directory not a Wordpress URL (correct me if I'm wrong). So if that doesn't works, just go to your htdocs (/var/www/html or opt/lampp/htdocs in Linux) directory (or where your wordpress is stored) and move it to other folder (like My documents) where you can backup it, and that's it, you can create that folder and keep following that tutorial. Commented Dec 23, 2016 at 22:39
  • I missed the first part of this guy's tutorial. He was using Sublime text, and he simply dragged his project directory into his htdocs folder so when it was executed it opened in localhost. The difference with mine is that I'm writing it in PhpStorm, and I had to configure php with a particular port. I'm fine with that for creation and debugging. I'll just copy the files into my localhost later, or onto whatever host I choose once it's live. Thanks for the tip. :-) If you want, go ahead and post your comment as an answer so I can mark it as answered. Commented Dec 24, 2016 at 17:22

1 Answer 1

1

Just move your Wordpress outside your htdocs folder...I think he is using something like XAMPP so in that way is very easy to do it, because the folder without an index will be detected as a directory not a Wordpress URL (correct me if I'm wrong). So if that doesn't works, just go to your htdocs (/var/www/html or opt/lampp/htdocs in Linux) directory (or where your wordpress is stored) and move it to other folder (like My documents) where you can backup it, and that's it, you can create that folder and keep following that tutorial.

Sign up to request clarification or add additional context in comments.

1 Comment

Thank you for the tip. I realized that this was such a simple task. I wasn't even thinking. I put my WordPress into a zip and just stashed it somewhere in case I want to use it again, set up my apache 000-default config file, edited my etc/hosts file so that 127.0.0.1 would map to my project with a domain name, edited permissions, placed my php project inside the directory and I'm good to go! :)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.