Title: custom sections
Last modified: August 18, 2016

---

# custom sections

 *  [kenkam](https://wordpress.org/support/users/kenkam/)
 * (@kenkam)
 * [20 years, 2 months ago](https://wordpress.org/support/topic/custom-sections/)
 * I want to make different sections for my site where each section’s layout differs
   slightly with the other ones. Because of this, the wordpress pages wouldn’t cut
   it for me. I am looking for a way to redirect users to custom php files.
 * e.g. my theme folder could look like this
    theme/section1.php theme/section2.
   php theme/home.php theme/header.php theme/index.php theme/footer.php …
 * and my URIs for them could be
    mydomain.com/section1/ mydomain.com/section2/
 * I was thinking of using a simple php script at index.php like this:
 * `
    if( $_SERVER['REQUEST_URI'] == '/section1/' ) { include( './section1.php' );}
   elseif { $_SERVER['REQUEST_URI'] == '/section2/' ) { include ( './section2.php');}
   else { include ( './home.php' ); }  home.php would be the homepage. section1.
   php and section2.php would be my section files.
 * Would this be a feasible way around it?

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

 *  [Chris_K](https://wordpress.org/support/users/handysolo/)
 * (@handysolo)
 * [20 years, 2 months ago](https://wordpress.org/support/topic/custom-sections/#post-373481)
 * You know… you could use multiple page templates for your pages, each page template
   being slightly different layout than others.
 * See this link for more info [http://codex.wordpress.org/pages#Page_Templates](http://codex.wordpress.org/pages#Page_Templates)
 * Does that help or did I miss the point completely?
 *  [Dgold](https://wordpress.org/support/users/dgold/)
 * (@dgold)
 * [20 years, 2 months ago](https://wordpress.org/support/topic/custom-sections/#post-373489)
 * Page Templates, same thing I thought of. That looks like page templates, to me.

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

The topic ‘custom sections’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 2 replies
 * 3 participants
 * Last reply from: [Dgold](https://wordpress.org/support/users/dgold/)
 * Last activity: [20 years, 2 months ago](https://wordpress.org/support/topic/custom-sections/#post-373489)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
