Title: Using a sub directory
Last modified: August 21, 2016

---

# Using a sub directory

 *  [jhmblvd](https://wordpress.org/support/users/jhmblvd/)
 * (@jhmblvd)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/using-a-sub-directory/)
 * I developed a site in a sub directory and followed the instructions given here:
   
   [http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory](http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory)
 * there is a WP site in valleyinstall.com
    I developed the site in valleyinstall.
   com/wpu
 * And I very carefully followed each step, However once I change the url in general
   settings of the wpu directory, then copy the htaccess and index.php into the 
   root, It breaks. I made a backup, but what happens is I can’t get back into the
   install on the wpu directory. If I go to valleyinstall.com/wpu/wp-admin and enter
   the credentials for that directory, the url changes to valleyinstall.com/wp-admin
   and I am given the shaking wrong credentials warning. I can get into the root
   directory but not the sub-directory. I can see it in my cPanel, but just can’t
   access it. Please help.

Viewing 2 replies - 1 through 2 (of 2 total)

 *  [Umesh Kumar](https://wordpress.org/support/users/umeshsingla/)
 * (@umeshsingla)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/using-a-sub-directory/#post-3724143)
 * To make it working have you made suitable changes to your database, go to your
   database manager, Select your database, search for “valleyinstall.com/wpu” and
   replace it with “valleyinstall.com” ? ?
 *  [govpatel](https://wordpress.org/support/users/govpatel/)
 * (@govpatel)
 * [13 years, 1 month ago](https://wordpress.org/support/topic/using-a-sub-directory/#post-3724338)
 * When using wordpress from a directory all you need to do is copy index.php file
   that is in your wpu directory and change line 17 and add your directory so you
   have
 * require(‘./wpu/wp-blog-header.php’);
 * and change Site url in settings General to be your root url leave the other as
   is and reset your permalinks.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Using a sub directory’ is closed to new replies.

## Tags

 * [redirected](https://wordpress.org/support/topic-tag/redirected/)

 * In: [Installing WordPress](https://wordpress.org/support/forum/installation/)
 * 2 replies
 * 3 participants
 * Last reply from: [govpatel](https://wordpress.org/support/users/govpatel/)
 * Last activity: [13 years, 1 month ago](https://wordpress.org/support/topic/using-a-sub-directory/#post-3724338)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
