[Beginner]Work with WordPress Post.
-
Hi everyone ??
First, if I’m in the wrong section, sorry.
My problem is that I try to get the last post on one page, and all the post in other one.I have create two page in the wordpress interface and have attach them a different model.
The first model is for the index page, where I just want to get and show the last post, and the second is the actuality page, where i try to get all the post.But I didnt have find how to do.
I have check on the codex how they do, but when I have try, that doesnt work.
Nothing was visible.Was something like :
[code]if(have_post()) : while(have_post) : the_post()
the_content();
endwhile;
endif;[/code]But really dont work. I think I’m doing something bad, like my actuality page model should be like :
[code]get_header();
"the loop juste before"
get_footer();[/code]
This should be a very simple sample for understand how that work but..
If someone can explain me, not juste copy past a solution, for how I can get only the last post, and get all the post, it will be very nice.Thanks for read and sorry for that “anglish”, I’m French.
- The topic ‘[Beginner]Work with WordPress Post.’ is closed to new replies.