PDA

View Full Version : Multiple Pages



Mike
05-10-2003, 02:07 PM
Hi there,

Would anybody be kind enough to tell me how you split an article or any other piece of content, into pages, like done on this site.

From what i've seen, it's done in PHP - but how please?

Mike

Chris
05-11-2003, 06:49 AM
You basically have 2 tables in your db.

One table is called articles and has article information like who the author is (authors is a third table) the article title, publication date, abstract, category, etc.

The other table is called pages, it has ArticleID, PageID, PageNum, PageTitle, PageAbstract, and PageText

Mike
05-11-2003, 09:32 AM
So do you enter the text in a different form for every page?

Thanks,
Mike

Chris
05-11-2003, 06:42 PM
Yes

Mike
05-12-2003, 08:45 AM
Thanks Chris.

ppunk0
10-12-2005, 08:36 AM
I am trying to split up an article into multiple pages, with the next, previous buttons and the 1 2 3 4 etc buttons.
Can anyone explain further on how to do this with 2 database tables as mentioned above? I am not a PHP/MySQL expert, so I have a hard time coming up with database design/layouts and setting up the PHP for it. I know basic PHP and have set up a membership system and learned some techniques on filtering and so on.
Also, I might need some help with the PHP as well, with setting up the next, previous and number section to navigate through the article.
Any additional help would be great!
Thanks!

-Steve

freekrai
10-13-2005, 07:12 AM
http://www.quickpipe.com/2_tutorials/36_building_a_multi-page_article_system_in_aspphp.html

ppunk0
10-13-2005, 08:44 AM
That is article is helpful, but it says that 'The entire code for this article is available in the support material link on the last page'. There is no link for this though.
It makes it harder for me because I am not too familar with getting the JavaScript to work with the form items (textfields/buttons). That article doesn't even cover all the code, like the up/down buttons, clear content, update page, etc.
I am not an expert in PHP/MySQL/JavaScript, so I can't complete this on my own. I am learning little by little, but it is tough on my own.
Is there a link to the entire code for that article or can someone help me fill in the blanks?
Thanks for posting that article, it got me pointed in the right direction.

-Steve

freekrai
10-13-2005, 08:47 AM
Fine, then read it from the original source where it was reprinted from:
http://www.interspire.com/whitepapers/index.php?pageName=Build_a_multi-page_Article_System_using_PHP%20or%20ASP

There was a link on that article to the site. And it is the full code, I know, I used that article to teach myself multi-page CMS work originally which is why I know it is the full code.

The article was linked here to show you an example of how it's done more than say here it is already done for you.

You still have to figure out how to let people edit an article using this technique.