front page won't change templates
Domanda
I have tried changing the template of the attached page and changing which page is attached as the home page, no effect for either. The front page remains the same. I am at my wits end with this one!!
Soluzione
What is your setup for front page in Settings > Reading
?
Do you have front-page.php
template in your theme? It will pretty much override anything, no matter what you choose in settings.
Altri suggerimenti
ok, the question is from 9 years ago but the answer is still valid:
function custom_template () {
return locate_template ('page_custom.php', false);
}
add_filter ('frontpage_template', 'custom_template');
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a wordpress.stackexchange