Wordpress

For the homepage you can either create a file called home.php place it in the theme folder and it will be used by default for the front page, or you can create 2 WP “pages” for home and blog then under settings > reading you can chose to display that home page as the front page and move the blog posts to the other page: For custom page templates: http://codex.wordpress.org/Pages#Page_Templates

If you watch the 3rd video that I posted in my prior post, Chris explains all of that.

i guess i should just create the index php file and then create the blogtemplate.php file with the loop in there for the posts.

No. Blogtemplate.php is not a standard file, so wordpress will not know what to do with it… Althuogh you could make that file, you could only apply it to a specific page, not wp as a whole.

i pulled this out of page.php but it appears that it is just like a blog post not a page post, am i correct or what?

		<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
		<div class="post" id="post-<?php the_ID(); ?>">
		<h2><?php the_title(); ?></h2>
			<div class="entry">
				<?php the_content('<p class="serif">Read the rest of this page &raquo;</p>'); ?>

				<?php wp_link_pages(array('before' => '<p><strong>Pages:</strong> ', 'after' => '</p>', 'next_or_number' => 'number')); ?>

			</div>
		</div>
		<?php endwhile; endif; ?>
	<?php edit_post_link('Edit this entry.', '<p>', '</p>'); ?>
	
	<?php comments_template(); ?>
	
	</div>

Pages are treated as posts, yes. You could of course change the CSS classes to “page” if you want.

EDIT: This is an extract from my own page.php, from the blog linked to in the name in my signature.

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

			<div id="post-<?php the_ID(); ?>" class="<?php hybrid_entry_class(); ?>">

				<?php hybrid_before_entry(); // Before entry hook ?>

				<div class="entry-content">
					<?php the_content(); ?>
					<?php wp_link_pages( array( 'before' => '<p class="pages">' . __( 'Pages:', 'hybrid' ), 'after' => '</p>' ) ); ?>
				</div><!-- .entry-content -->

				<?php hybrid_after_entry(); // After entry hook ?>

			</div><!-- .hentry -->

			<?php hybrid_after_singular(); // After singular hook ?>

			<?php comments_template( '', true ); ?>

			<?php endwhile; ?>

		<?php else: ?>

			<p class="no-data">
				<?php _e( 'Sorry, no page matched your criteria.', 'hybrid' ); ?>
			</p><!-- .no-data -->

		<?php endif; ?>

Yes “pages” are very similar to “posts”. This code is the same as the other files. It contains The Loop. This file will be used when it is displaying a post that is labeled as “paged” in the database. :slight_smile:

http://codex.wordpress.org/Pages#Pages_in_a_Nutshell

so then image.php is also the same? this is so confusing.

Not familiar with image.php. What theme are you using? This might be a custom file made for this theme.

using the default theme

What do you know there is a file called image.php in the default theme. Been so long since I looked at it I guess it slipped past me. It appears that this file is used when you link an image to the post-file in the image uploader. Clicking said image displays a page with the image larger and a caption. I have never used this file so I can not be much more help on it.

oh ok so its not important in my case.

i guess now i got to tackle the archive and the search php file.

hello,

so i installed the template that i was working on and now i get this problem were no images are shown and the css doesn’t seem to function. please help:

www.polar-pos.com/blog/

what is going on?

I notice you have links to 2 style sheets in the head:

<link href="css/index.css" type="text/css" rel="stylesheet" />
<link rel="stylesheet" href="http://www.polar-pos.com/blog/wp-content/themes/awp/style.css" type="text/css" media="screen" />

The first one returns a 404 error and the second one is the default theme style sheet.

no i renamed index.css to style.css but it still won’t work :frowning:

You need to replace the default .css file with the .css file you have made for your layout. It goes in the active theme folder. You need to make sure that the file has the following at the top of it: http://codex.wordpress.org/Theme_Development#Theme_Style_Sheet

i done that exactly, in the same folder were it has index.php i have style.css with that at the top.

the image folder doesn’t work as well there is something up.

Looks like it is at least partially sorted.

The images, are here: /blog/wp-content/themes/awp/images/future_slide.jpg

But the file is looking for them in the root of your blog install: /blog/images/future_slide.jpg

What additional problems are you having?

that is really weird the code just says images/whatever-image.jpg

i checked other templates that’s how they got it setup :X

how can i fix tha tissue?