Jump to content

Is there a way to auto generate pages?


Shyke

Recommended Posts

Hi, so i kinda planned to code a new project.

But i'm not quite sure about this.

 

I could imagine you could pull the pages out.

 

 

So let me explain.

 

 

 

So i believe google is generating these numbers automatically and automatically linking it to a page.

Is there a way to do that easily? Would help me alot.

post-172707-0-85574400-1409254912_thumb.png

 

So if i have 50 result per page.

Thats the thing i want!

 

If 50 result = > then new page!

And then it should create a new number down there.

 

 =)

Any questions?

ASK ME! :D

Link to comment
https://forums.phpfreaks.com/topic/290709-is-there-a-way-to-auto-generate-pages/
Share on other sites

Well, just think about it.

 

If you have, say, 210 results, how many pages are there? How do you calculate this number?

 

When you know that, all you need is a for loop and a way to include the page number in the URL. The latter can be as simple as adding a page parameter:

https://yoursite.com/list.php?page=123

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.