Hallo!
Kann mir mal jemand sagen, warum mein Page to Front-Plugin nicht funktioniert?:
PHP
<?php
/*
Plugin Name: Page to Front
Version: 1.0
Plugin URI: http:/ /wordpress.org/
Description: Choose a page from the DB to display as the front page of your weblog.
Author: Ryan Boren
Author URI: http:/ /boren.nu
*/
// Put the id of the page you want to display here. To find the page id,
// go to Manage–>Pages in the admin UI and look at the ID column.
$ptf_front_page = 2;
function ptf_front_page($query_string) {
global $ptf_front_page;
$query = new WP_Query();
$query–>parse_query($query_string);
if ($query–>is_home) {
$query_string = add_query_arg('page_id', $ptf_front_page, $query_string);
{
return $query_string;
{
add_filter('query_string', 'ptf_front_page');
?>
Alles anzeigen
Bin ich etwa blind?!