0

Hello!
Anyone here can explain me please how to create a website that with pages and that works like blogger or wordpress. (I mean, for example: the page have a post limit by 6 post's. if I post something new on my website I want that the first post move instead the second post and the second post to move instead the 3 post ect. the same thing for all post's. When the number of post's for every page, reach 6 posts, automatically I want to be created a new page. another thing: each post will have labels.) So I want the website work like news feed, like blooger, facebook, wordpress ect. I hope everything is clear. If not please let me know.
Thanks!

2
Contributors
4
Replies
36
Views
2 Years
Discussion Span
Last Post by Elvi
0

If you want to code it yourself:

1) Store all posts in a database

2) For your first page, select posts from the database, with an 'ORDER BY time DESC' clause where time is the time the post was produced (order the posts newest first) and a 'LIMIT 6' clause on the end (this will select the first 6)

3) Check whether there are more posts (if so, create another page)

4) Use the page number of the new page to determine the starting index of the posts to select from the database (page 2 will start at index 6 (item 7) - assuming that the database entries are zero-based). Your LIMIT clause would be 'LIMIT 6, 6'

This should get you started in the right direction

0

Thanks for reply!
I want to make a website for movies. Will I use MySQL? I dont know too much about it.

0

Yep, I would go for MySQL, it integrates really well with PHP and there's loads of information online to help you start out.

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.