Wordpress Themes - WP Forum at BFA
There will be no more development for Atahualpa (or any other theme), and no support. Also no new registrations. I turned off the donation system. I may turn the forum to read only if it gets abused for spam. Unfortunately I have no time for the forum or the themes. Thanks a lot to the people who helped in all these years, especially Larry and of course: Paul. Take care and stay healthy -- Flynn, Atahualpa developer, Sep 2021

Wordpress Themes - WP Forum at BFA » WordPress Themes » Montezuma Theme »

[SOLVED] setting a virtual template for the front page


  #1  
Old Jun 19, 2013, 04:23 PM
emanuel1969's Avatar
emanuel1969
 
133 posts · Apr 2010
California
Send a message via Skype™ to emanuel1969
[SOLVED] setting a virtual template for the front page

Hi everyone,

So I am creating my first website in Montezuma, and I can't figure out how to get my front page to use a different template. My front page is a static page named "home".

So I made a main template called "slider.php" that I want to apply to the front page, but when I assign the page "home" to the slider.php template, it does not work.

I also tried changing the main template "index.php" and assigning the "home" page to it. But that didn't work.

Can someone help?

Thanks!
Emanuel
__________________
Emanuel
http://www.sferios.com
  #2  
Old Jun 19, 2013, 04:40 PM
emanuel1969's Avatar
emanuel1969
 
133 posts · Apr 2010
California
Send a message via Skype™ to emanuel1969
Ok I have learned more. The virtual main template is actually working fine. It's a sub template that is not embedding into the virtual template. I made a sub template called "header2.php" and the following code in the virtual main template is not working:

<?php get_header2(); ?>

What am I not understanding here? How do I embed a newly-created sub template into a new main template?
__________________
Emanuel
http://www.sferios.com
  #3  
Old Jun 19, 2013, 04:48 PM
emanuel1969's Avatar
emanuel1969
 
133 posts · Apr 2010
California
Send a message via Skype™ to emanuel1969
So continuing... I got rid of the header2.php sub template and just put the code directly into my slider.php main template. That seems to work, but ONLY for page-type pages. When I assign it to my statically-defined front page (called "home") it does not work.

So it seems there is a problem trying to assign the front page to a virtual template. Or at least I'm still not getting it.
__________________
Emanuel
http://www.sferios.com
  #4  
Old Jun 19, 2013, 05:06 PM
emanuel1969's Avatar
emanuel1969
 
133 posts · Apr 2010
California
Send a message via Skype™ to emanuel1969
Ok I found in the instructions that you are supposed to be able to add a new header sub template to a main template by using this php code:

<?php get_header( '2' ); ?>

But it didn't work. I named the sub-template header-2.php like I was supposed to, and I called it up in my new main template (slider.php) using the php code above. Then I assigned slider.php to my front page ("home") with no luck. Then I tried assigned slider.php to a regular page on the site and it also did not work.

Sooooo.....

I am still stuck trying to figure out two things:

1. How to get a new main template to appear on a static front page.
2. How to embed a sub template into a new virtual main template.

Thanks!
__________________
Emanuel
http://www.sferios.com
  #5  
Old Jun 19, 2013, 05:16 PM
jerryc
 
367 posts · Oct 2012
Florida
See this post.
  #6  
Old Jun 19, 2013, 05:34 PM
emanuel1969's Avatar
emanuel1969
 
133 posts · Apr 2010
California
Send a message via Skype™ to emanuel1969
Thanks jerryc.

That answers my second question, but I still cannot assign a new template to my front page (a static page) no matter what I try.
__________________
Emanuel
http://www.sferios.com

Bookmarks



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Help setting up page template for Jigo Shop Tim F Plugins & Atahualpa 8 Feb 15, 2013 03:49 PM
Error on Page / Virtual Template = image colin123456 Montezuma Theme 1 Jan 28, 2013 03:49 AM
once I create a virtual template, where do I edit it. LGL Montezuma Theme 1 Jan 16, 2013 03:58 PM
PATCH 113-03: Using 'the_content()' in a virtual template may incorrect results juggledad New Versions & Updates 0 Jan 6, 2013 02:07 PM
[SOLVED] Edited virtual template changes not showing up jerryc Montezuma Theme 2 Oct 5, 2012 10:24 PM


All times are GMT -6. The time now is 12:45 AM.


Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.