Ever wanted to put up a quick holding page for a live site while you do some sneaky work behind the scenes?
Ever wanted to put up a quick holding page for a live site while you do some sneaky work behind the scenes? You know; there’s a few styling or functionality features you want to add that will temporarily break the site but you don’t have the time or resources (or it’s not worth it) to pull down a complete local copy to work on. Well, here’s a quick and easy way to do this in WordPress:
Firstly, create a new php file in you themes directory (wp-content/themes/YOUR-THEME-DIRECTORY) called holdingpage.php. Your template name gets defined at the top (“Holding Page” in this example; WordPress uses this commented line to render your template name in the CMS):
The rest of the page can contain anything from a simple html message (“Site temporarily under construction” or something like that) to a full html version of your site styled up to the hilt (just remember to exclude any navigation links: we don’t want visitors to be able to click through to pages that you’re busy breaking with your behind-the-scenes coding!).
Next, create a new page in the CMS and call it something like “Holding Page”. In the Page Attributes box on the right, set the page template to your newly-created “Holding Page” (which should now be one of the options available in the dropdown). Save and publish this new page. It needn’t have any content at all; that can all be defined in holdingpage.php.
Nearly there. All you have to do now is go to Reading Settings (under the “Settings” menu on the left of your Dashboard) and set the Front Page to your newly-created “Holding Page”, which should now be visible in the dropdown.
That’s it! Now when someone visits your site they’ll just see your holding page while you get your hands grubby in the code behind the scenes.
(Note: this is obviously only a quick-fix solution suitable for small tweaks and fixes, not large chunks of development work)