[wp-hackers] displaying a 1.3 "Page" on a different index

cFA cfanyc at gmail.com
Mon Oct 11 14:17:44 UTC 2004


Hi There, this is my first post to the list and im real glad there are
alot of experts here...  I was very excited about the page feature in
1.3 so I installed it and have one thing that I need to know how to do
to get a huge breakthru on a site im working on..(  I know about the
alpha testing, and if there is an attainable solution with 1.2 (which
im running on another site, im open to that as well).

I have created a page that I want  to display on a different index.php
and I dont want it showing up on the main wp index at all, ever.

here is my setup:

I have a directory called "features" in this directory is my wordpress
folder("wp")

and another folder "01" that has the index.php I want to display my page on.  

I have setup my permalinks like so : %postname%  

my page link looks like this:
http://mysite.com/features/wp/this-is-mypage/

now, on the index.php in the  01 folder I have put this code at the top:

<?php
/* Don't remove this line. */
$blog = 1;
if (!isset($p)) {
$p = "this-is-mypage";
}
require('../wp/wp-blog-header.php');
?>

In the div that I want the entry displayed in I have this:

<div id="contentfeat">
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
<?php the_date('','<h2 class="dateicon">','</h2>'); ?>
<div class="post">

<h3 class="storytitle" id="post-<?php the_ID(); ?>"><a href="<?php
the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h3>

<div class="meta"><?php _e("Filed under:"); ?> <?php the_category(',')
?> | <img src="graphics/author.png" width="11" height="10" border="0"
alt="" /> <?php the_author_firstname() ?> @ <?php the_time() ?> <?php
edit_post_link(__('Edit This')); ?></div>

<div class="storycontent">
<?php the_content(__('(more...)')); ?>
</div>

<div class="feedback">
<?php wp_link_pages(); ?>
<?php comments_popup_link(__('Comments (0)'), __('Comments (1)'),
__('Comments (%)')); ?>
</div>
</div>

<?php comments_template(); // Get wp-comments.php template ?>

<?php endwhile; else: ?>
<p><?php _e('Sorry, no posts matched your criteria.'); ?></p>
<?php endif; ?>

<?php posts_nav_link(' &amp;#8212; ', __('&amp;laquo; Previous Page'),
__('Next Page &amp;raquo;')); ?>
</div>

---now when I view the page I get the "Sorry no posts matched your
criteria"  This is probably because Ive not used the right code
somewhere here..

can someone spot what Im doing wrong, and help me out.. i would really
appreciate it as Ive been stumped a few days on this..

many thanks
clint



More information about the hackers mailing list