/    Sign up×
Community /Pin to ProfileBookmark

News section question

Right now I have a News/Updates Section on the homepage of a website I’m working on. It working great but I’m wondering how I’ll be able to handle the mass amount of news/updates to come. For example, right now every post a user makes is stored on a single page (live_news.php). Now, once this website gets public, the owner anticipates a lot of news to be shown. The thing is, I’m afraid the page will end up being so incredibly long, that the users will have a hard time loading it. Is there a way I can span the older news post onto other pages (Page 1, 2, 3, 4, 5, etc) with about 5-7 posts on each page?

Now, I know it’s possible, because I’ve seen it almost everywhere. So if anyone could lend a hand it would be greatly appreciated =)!

[URL=http://oshawapss.ca/testing/AQUA/home.php]Here is the page[/URL] that will show the news. If you want the code just let me know!

Thanks!

to post a comment
PHP

8 Comments(s)

Copy linkTweet thisAlerts:
@bokehAug 16.2006 — Yes, it's called pagination.
Copy linkTweet thisAlerts:
@sheepo-designsauthorAug 16.2006 — is [URL=http://api.rubyonrails.com/classes/ActionController/Pagination.html]this what you mean[/URL]?
Copy linkTweet thisAlerts:
@bokehAug 16.2006 — That is ruby (nothing to do with php). Are the news items being stored in MySQL?
Copy linkTweet thisAlerts:
@sheepo-designsauthorAug 17.2006 — I wasn't planning on it. But it al depends on what kind of host m client is looking for. I know most popular hosts support MySQL, but my client is looking into bying their own sever. They have their own server right now, but it was setup to ony support a single page website.

Would it be easier to use MySQL? or just to create text files for every news/update posted?
Copy linkTweet thisAlerts:
@pcthugAug 17.2006 — MySQL would be more secure, efficient, accessible and manipulative then a flat-file system. MySQL is the preferred data storage solution when working with PHP; it is open-source (free), tightly integrated with PHP and is reasonably powerful.
Copy linkTweet thisAlerts:
@sheepo-designsauthorAug 17.2006 — I've tried working with MySQL before, it proved to be wuite complicated. Do you know of anywhere to take tutorials? or is this a Google situation?
Copy linkTweet thisAlerts:
@sheepo-designsauthorAug 17.2006 — Wow thanks a lot pcthug!
×

Success!

Help @sheepo-designs spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.5,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,

tipper: @Samric24,
tipped: article
amount: 1000 SATS,
)...