Link between Home.php and index.php
-
I have home.php which include a big picture and description of my website.
and a index.php that will be the blog page that show all the posts.This is my theme folder
/themes/mytheme/ index.php home.php header.php footer.php header-blog.php header-blog.php
code for index.php
<?php /* * Template Name: Index */ get_header(blog); ?> <div id="main"> <div id="content"> <?php if (have_posts()) : while (have_posts()) : the_post(); ?> <h1><?php the_title(); ?></h1> <h4>Posted on <?php the_time('F jS, Y') ?></h4> <p><?php the_content(__('(more...)')); ?></p> <hr> <?php endwhile; else:?> <p><?php _e('Sorry, no posts matched your criteria.'); ?></p><?php endif; ?> </div> <?php get_sidebar(); ?> </div> <div id="delimiter"> </div> <?php get_footer(blog); ?>
My Question is:
1)I need to create a link in Home.php(homepage) that allow will prompt to index.php(blog page) like below:
<li><a href="Blog">Blog</a></li>
www.mysite.com/Blog
2)the blog preview is not available(404 page not found), and i cannot view my blog at all now.
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Link between Home.php and index.php’ is closed to new replies.