Home > internet jurnal > How To Setting LinkEX on Page Wordpress

How To Setting LinkEX on Page Wordpress

November 28th, 2008 defomaz Leave a comment Go to comments

Sebelumnya jangan lupa baca overviewnya di  LinkEx PHP Link Exchange Management Sederhana tapi Mantab nah lanjutannya sekarang gimana sih setting LinkEx di Page template wordpress.

caranya Sangat mudah sebagai berikut :

1. Buat satu page dengan judul Link Exchange

2. Edit Page Template ( page.php )

default page.php for blubbr wordpres template

<?php get_header(); ?>

<div class=”left”>

<div class=”left_articles”>

<?php if (have_posts()) : while (have_posts()) : the_post(); ?>

<h2><a id=”post-<?php the_ID(); ?>” href=”<?php the_permalink(); ?>” rel=”bookmark” title=”Permanent Link to <?php the_title(); ?>”"><span><?php the_title(); ?></span></a></h2>
<p>
<?php the_content(”); ?>
</p>
<?php edit_post_link(’<br /> Edit this page’,”,”); ?>
<?php comments_template(); ?>
<?php endwhile; ?>

<?php else : ?>
<h2>Not Found</h2>
<p>Sorry, but you are looking for something that isn’t here.</p>
<?php include (TEMPLATEPATH . “/searchform.php”); ?>
<?php endif; ?>
<div style=”clear:both”></div>

</div>
</div>

<?php get_sidebar(); ?>
<?php get_footer(); ?>

dirbah menjadi

<?php get_header(); ?>

<div class=”left”>
<div class=”left_articles”>

<?php if (is_page(’Link Exchange’)) : the_post();?>
<h2><a id=”post-<?php the_ID(); ?>” href=”<?php the_permalink(); ?>” rel=”bookmark” title=”Permanent Link to <?php the_title(); ?>”"><span><?php the_title(); ?></span></a></h2>
<p>
<?php the_content(”); ?>
</p>
<?php include( “linkex/data/output/1003″ ); ?>
<?php edit_post_link(’<br /> Edit this page’,”,”); ?>
<?php comments_template(); ?>

<?php elseif (have_posts()) : while (have_posts()) : the_post(); ?>
<h2><a id=”post-<?php the_ID(); ?>” href=”<?php the_permalink(); ?>” rel=”bookmark” title=”Permanent Link to <?php the_title(); ?>”"><span><?php the_title(); ?></span></a></h2>
<p>
<?php the_content(”); ?>
</p>
<?php edit_post_link(’<br /> Edit this page’,”,”); ?>
<?php comments_template(); ?>
<?php endwhile; ?>

<?php else : ?>
<h2>Not Found</h2>
<p>Sorry, but you are looking for something that isn’t here.</p>
<?php include (TEMPLATEPATH . “/searchform.php”); ?>
<?php endif; ?>
<div style=”clear:both”></div>

</div>
</div>

<?php get_sidebar(); ?>
<?php get_footer(); ?>

Perhatikan pada

<?php if (is_page(’Link Exchange’)) : the_post();?> // filter jika title page adalah link exchange
<h2><a id=”post-<?php the_ID(); ?>” href=”<?php the_permalink(); ?>” rel=”bookmark” title=”Permanent Link to <?php the_title(); ?>”"><span><?php the_title(); ?></span></a></h2>
<p>
<?php the_content(”); ?>
</p>
<?php include( “linkex/data/output/1003″ ); ?>
<?php edit_post_link(’<br /> Edit this page’,”,”); ?>
<?php comments_template(); ?>

Done. contohnya disini http://www.satudetik.com/link-exchange/ Selamat mencoba.

VN:F [1.1.4_465]
Rating: 0.0/10 (0 votes cast)
Categories: internet jurnal Tags:
  1. December 17th, 2008 at 15:56 | #1

    brrr, coding selalu njelimet :p
    dengan php saya cuma bisa ‘hello world” hehe..

    VA:F [1.1.4_465]
    Rating: 0.0/5 (0 votes cast)
  1. No trackbacks yet.