• Hi

    I’ve been studying web design in my free time mainly building static sites and have just started to explore wordpress with it’s CMS function. However I’ve just created a dummy 4 page site via watching tutorials please see: https://creative-media.info/wp/
    I’ve created a standard theme with header, main content, footer and rightside sidebar however the blog now appears on all pages in the main section.

    I’ve created my own custom page template for the contact us page ( map2.php) however the footer is now coming above the main content area and sidebar. Please weblink for reference: https://creative-media.info/wp/contact-us/

    I’ve tried searching the web for solutions and amended the code, but I’ve been unable to correct this issue. I only have a very basic understanding of PHP and I am looking to create a business style website that contains 4 x page with 3 pages having a main content area and 1 x pages being for the blog, any help or examples of code that I can amend would be greatly appreciated.

    example below of code used in map2.php – out of interest how would you make each page have an editable content area. I.e. my understanding is if you use a sidebar function this would need to be numbered and this means the same content would be displayed on all pages.

    Example code used for my bespoke contact us page template is:

    <?php
    /*
    Template Name: map2
    */
    ?>
    <?php get_header(); ?>

    <div id=”map”> </div>

    <?php get_footer(); ?>

Viewing 1 replies (of 1 total)
  • compare the code for page.php and the page template, to see if you are using the same html structure and css classes.

    try working with a browser inspection tool (such as Firebug, or the right-click ‘inspect element’ of some modern browsers) to find out how header, content, and footer etc are formatted; compare a ‘normal’ page with the one using the page template ….

    further, check the code validation with https://validator.w3.org/ or similar; this might give you more clues about what might be wrong.

    not really a WordPress problem (?)

Viewing 1 replies (of 1 total)
  • The topic ‘Creating custom page template’ is closed to new replies.