Creating Custom Template Files

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • #6989

    Greetings. Thank you for a wonderful theme.
    I am trying to create custom template files and am running into a problem. My first step when doing this is always to duplicate the file exactly from the provided template files. In this case I am working with the page-sc.php where it is Content and a Sidebar on the left. When I duplicate this file, give it a new name and edit the template file to use the new name (everything else is exactly the same) it reverts to side-content-side in the display. I cannot seem to determine why this is happening. Do you have any suggestions?


    I suppose there is something to be said about perseverance. I believe I found the problem AND what may be considered a flaw in the theme. It would appear that the Frontier theme is not coded correctly to support page templates without additional CSS formatting being done. In the styles.css file there are specific classes for the included page templates. If you are creating your own page template, you must add CSS to make this work.

    Example: I duplicated and renamed the ‘page-sc.php’ file to ‘page-building.php’
    In the style.css file I found this entry:

    .page-template-page-sc-php #main #content {float: right;}
    .page-template-page-cs-php #main #content {float: left;}
    .page-template-page-scs-php #main #content  {float: none;}
    .page-template-page-scs-php #main #sidebar-left {
    	float: left;
    	margin-right: 0;
    .page-template-page-scs-php #main #sidebar-right {
    	float: right;
    	margin-left: -4px;

    In order to get my page template to behave correctly, I had to make the following additions:

    .page-template-page-building-php #main #content {float: right;}
    My page template file is ‘page-building.php’ so when it is called it will reference this css and work correctly.

    I hope this helps someone and possibly gets some attention in future releases.

Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘Frontier’ is closed to new topics and replies.