Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

There is a static page named pcmuskel.de/ratgeber. Trying to access this URL wordpress redirects me to the frontpage.

I had this page set up as frontpage before but it didn't work. The frontpage showed the last articles instead.

How can I set the static page as frontpage? There is an error or bug because I set it up in the settings and is didn't work like described. But the menu item of the static page becomes active on the frontpage.

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

You can have your static page ratgeber but you need to add it to WordPress first.

So open your ratgeber file and add this to the top of it ...

<?php
/*
Template Name: ratgeber
*/
?>

Save the file in your theme folder.

Now go to WordPress > All Pages > add page
and from the Template drop down choose ratgeber
enter image description here

Save and publish the page.

Finally ... go to WordPress > Settings and choose ratgeber as your static homepage.

share|improve this answer
    
ratgeber is a simple static wordpress page. Why do I need a custom template? –  danijar Aug 19 '12 at 9:32
    
Ok i wrote a front-page.php template file and now it is working. I don't understand why, front-page.php ist the same as index.php. But doesn't matter! ;-) –  danijar Aug 19 '12 at 9:52
    
@sharethis WordPress looks for index.php or frontpage.php in your theme folder and either of these 2 files are automatically loaded .... a custom template is needed because WordPress is a database driven CMS so you can't just create static files. –  Damien Aug 19 '12 at 11:58
    
By static I meant pages as they are a build in feature of wordpress. I just wondered why I need a frontpage and a index with the same content to can set a page to home in the settings. –  danijar Aug 20 '12 at 14:56
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.