Forum Replies Created

Viewing 1 replies (of 1 total)
  • The solution described above didn’t work for a website I developed: https://www.anacarmen.com

    Some small changes were necessary if you used the blog.php as described in https://codex.www.ads-software.com/Pages

    Instead of index.php, I used blog.php in the .htaccess file.

    RewriteRule ^(blog)/page/?([0-9]{1,})/?$ /blog.php?pagename=$1&pgd=$2 [QSA,L]
    RewriteRule ^(blog)(/[0-9]+)?/?$ /blog.php?pagename=$1&pgd=$2 [QSA,L]

    And I replaced the original code in blog.php with

    <?php $qy = preg_replace('/page_id=d*&?/','',$_SERVER['QUERY_STRING']); ?>
    <?php $qy = preg_replace('/pagename=w*&?/','',$qy); ?>
    <?php $qy = preg_replace('/page=w*&?/','',$qy); ?>
    <?php $qy = preg_replace('/pgd=(d*)(&?)/','paged=${1}${2}',$qy); ?>
    <?php $qy = $qy==''?'orderby=date':$qy; ?>
    <?php query_posts($qy);
    extract ($wp_query->query_vars);
    load_template( TEMPLATEPATH . '/index.php'); //loads index
    ?>

Viewing 1 replies (of 1 total)