Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

a couple of general questions about WordPress development

Posted on 2013-05-28
7
Medium Priority
?
258 Views
Last Modified: 2013-05-30
Hi friends. I am developing a web site in WordPress. The front page will look like the attached image; the interior pages will look somewhat different. I am new to WordPress. I have a few questions.

1) How can I develop different templates for WordPress -- front page template; internal page template; another internal page template; etc.?

2) I am using, as my framework, the Foundation WordPress theme, a free and responsive theme from http://fwp.drewsymo.com / Author: Drew Morris.

Do you suggest that I simply develop the CSS/HTML for these templates (front page; internal), and adapt that CSS/HTML to this framework? Or should I develop within the framework itself -- I have tried doing this, but my results are erratic since I do not fully understand how Drew Morris put together the CSS for this framework.

Please give me your advice. I am in a crunch to develop this site. Thank you very much for your time and expertise.

Eric
PALPARTNERS-ImageSmart-WEB-FINAL.jpg
0
Comment
Question by:Eric Bourland
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
7 Comments
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 39202421
You can create custom templates under any theme.

http://codex.wordpress.org/Pages#Page_Templates

I would stay within your chosen framework because all you need to do is modify the basic page template and change the existing HTML and CSS as you need.
0
 
LVL 3

Author Comment

by:Eric Bourland
ID: 39202555
Jason, thank you.

So, then, should I make separate templates for the front (index) page and the interiors pages?

Also, should I edit header.php and footer.php, if these will be the same for all pages?

Finally, do I ever edit page.php, if I am using only my custom templates?

Thank you again.

Eric
0
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 39202581
Yes, I would make separate templates for front and interior.   Read about Template Hierarchy on the WordPress codex to see how you can use templates in nifty ways.  

You can edit header and footer if you want to make global changes.  You can also use various WordPress conditional functions like is_home() to have special content for specific pages.  

You don't need to edit page.php if you are using your own templates unless you want a different default whatever to be present in page.php.
0
Looking for a new Web Host?

Lunarpages' assortment of hosting products and solutions ensure a perfect fit for anyone looking to get their vision or products to market. Our award winning customer support and 30-day money back guarantee show the pride we take in being the industry's premier MSP.

 
LVL 3

Author Comment

by:Eric Bourland
ID: 39202626
This is making more sense.

So, to create a new page template such as interior_page.php. I would begin that file thus:

<?php

/*

Template Name: interior_page

*/

?>



<?php get_header(); ?>

Open in new window


Correct?
0
 
LVL 70

Accepted Solution

by:
Jason C. Levine earned 2000 total points
ID: 39203550
Correct?

Pretty much.  A custom page template basically is this:

<?php
/*
Template Name: Name it.
*/
//Display the header
get_header();
//Display the page content/body
if ( have_posts() ) while ( have_posts() )
{
the_post();
the_content();
}
//Display the footer
get_footer();
?>

Open in new window


Just add HTML and CSS as needed to match the layout you have in your head.
0
 
LVL 3

Author Closing Comment

by:Eric Bourland
ID: 39208817
Jason, really helpful. Thank you very much. I might come back here with a few more questions. All best.

Eric
0
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 39208824
I might come back here with a few more questions.

That's what the site is here for.  Good luck!
0

Featured Post

Looking for a new Web Host?

Lunarpages' assortment of hosting products and solutions ensure a perfect fit for anyone looking to get their vision or products to market. Our award winning customer support and 30-day money back guarantee show the pride we take in being the industry's premier MSP.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

How to create your own WordPress Theme Before I begin with the theme design tutorial, I would like to give you the basics of what is required to make a WordPress Theme. The most basic WordPress theme only requires 2 files: a style.css file and an…
So you have coded your own WordPress plugin and now you want to allow users to upload images to a folder in the plugin folder rather than the default media location? Follow along and this article will show you how to do just that!
The purpose of this video is to demonstrate how to update a WordPress Site’s version. WordPress releases new versions of its software frequently and it is important to update frequently in order to keep your site secure, and to get new WordPress…
The is a quite short video tutorial. In this video, I'm going to show you how to create self-host WordPress blog with free hosting service.

661 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question