Title: How do you create a template
Last modified: August 19, 2016

---

# How do you create a template

 *  [jeffocal](https://wordpress.org/support/users/jeffocal/)
 * (@jeffocal)
 * [16 years, 10 months ago](https://wordpress.org/support/topic/how-do-you-create-a-template/)
 * I am tiring to generate a page template for [http://www.theimagineershome.com/blog/](http://www.theimagineershome.com/blog/)
   to use in a mailpress plug in. I the followed the instructions at [http://www.mailpress.org/](http://www.mailpress.org/)
   and transferred pt_MailPress.php to my wordpress nebula theme folder however 
   I cannot figure out how to create a page using this template because I am only
   give the option in the Admin>Write>Page to use the current theme. Could someone
   please try to explain to me how to generate “Id of Page using page template ‘
   pt-MailPress.php’” as the instructions indicate I should
 * I’d be extremely grateful.
 * Jeff
 * 1. You will find a page template pt_MailPress.php in the /xtras folder.
    2. This
   template can be adapted to your current WordPress theme. 3. This template must
   be in your current WordPress theme folder. 4. You have to create a page with 
   this template under Admin>Write>Page. 5. The “Id of Page using page template ‘
   pt-MailPress.php’” field must be filled accordingly.

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

 *  [Eric Mann](https://wordpress.org/support/users/ericmann/)
 * (@ericmann)
 * [16 years, 10 months ago](https://wordpress.org/support/topic/how-do-you-create-a-template/#post-1119107)
 * Jeff,
 * Now that you’ve added a template file to your theme directory, you need to deactivate
   and reactivate the theme (switch to a different theme, load your blog, and then
   switch back). Otherwise, WordPress doesn’t know you have a template file.
 * After you’ve reactivated the theme, you *should* have an additional option on
   the Page screen for the new template.
 *  Thread Starter [jeffocal](https://wordpress.org/support/users/jeffocal/)
 * (@jeffocal)
 * [16 years, 10 months ago](https://wordpress.org/support/topic/how-do-you-create-a-template/#post-1119138)
 * Should but isn’t. I tried several time but no go. Any Ideas
 * Jeff
 *  [Eric Mann](https://wordpress.org/support/users/ericmann/)
 * (@ericmann)
 * [16 years, 10 months ago](https://wordpress.org/support/topic/how-do-you-create-a-template/#post-1119197)
 * The alternative is to set the page template directly in the database itself. 
   This is tricky, can cause a lot of problems if done incorrectly, and requires
   you to be somewhat adept at working directly with the WP database through phpMyAdmin.
 * If you’re up to that, let me know and I’ll give you pointers.
 *  Thread Starter [jeffocal](https://wordpress.org/support/users/jeffocal/)
 * (@jeffocal)
 * [16 years, 10 months ago](https://wordpress.org/support/topic/how-do-you-create-a-template/#post-1119278)
 * Thanks Friend
 * Jeff
 *  [Eric Mann](https://wordpress.org/support/users/ericmann/)
 * (@ericmann)
 * [16 years, 10 months ago](https://wordpress.org/support/topic/how-do-you-create-a-template/#post-1119283)
 * OK. Here it is step-by-step:
 * 1) **Back up your site!**
    2) Create your template file and upload it to the 
   theme directory 3) Create a blank (or populated) page to use this template – **
   write down the page ID** 4) Log in to your database via phpMyAdmin 5) Go to the
   wp_postmeta table 6) Click “Insert” and put the following in the appropriate 
   fields:
 * **meta_id** -> leave this blank
    **post_id** -> the ID of the page you want to
   have the template **meta_key** -> “_wp_page_template” **meta_value** -> the filename
   of your page template, i.e. “custom.php”
 * 7) Click “Go” at the bottom of the page
 * Now when you go to the page, it should pull up the custom page template just 
   the way you want it. This isn’t the most elegant solution, but it works nonetheless.
 * Let me know if that gets you where you need to be.
 *  Thread Starter [jeffocal](https://wordpress.org/support/users/jeffocal/)
 * (@jeffocal)
 * [16 years, 10 months ago](https://wordpress.org/support/topic/how-do-you-create-a-template/#post-1119296)
 * Thankd friend that worked
 * Jeff

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

The topic ‘How do you create a template’ is closed to new replies.

 * 6 replies
 * 2 participants
 * Last reply from: [jeffocal](https://wordpress.org/support/users/jeffocal/)
 * Last activity: [16 years, 10 months ago](https://wordpress.org/support/topic/how-do-you-create-a-template/#post-1119296)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
