Home arrow Site Administration arrow Page 2 - Talk To Me!

The Job - Administration

You've seen how many Web sites (including this one) allow you topost comments and opinions on the material they publish. If you've everwished you had this capability on your Web site, or are simply curious asto how this is accomplished, read on.

TABLE OF CONTENTS:
  1. Talk To Me!
  2. The Job
  3. Building The Foundation
  4. Mole In A Hole
  5. Speak Now, Or Forever Hold Your Peace
  6. Of Trees And Branches
  7. Closing The Loop
  8. The Last Word
By: Vikram Vaswani, (c) Melonfire
Rating: starstarstarstarstar / 1
March 12, 2001

print this article
SEARCH DEV SHED

TOOLS YOU CAN USE

advertisement
Since we were called upon to graft this interactive comments system on to an existing Web site, we had to take into account the underlying architecture, as well as the customer's requirements and constraints, before beginning work on the applications. The first was a matter of a few hours; the second, a few weeks (if you're a developer, I'm sure you know *exactly* what I mean)

The underlying architecture of the Web site in question is actually pretty simple. The site is divided into a number of different top-level categories, like entertainment, news, politics, travel and the like. Each article on the site is represented by a record in a table; this table contains the title of each article, an abstract and the complete content of the article.

Each article (record) is identified by a category number and an article number - this combination is unique to each article, and makes it possible to immediately display a specific article. Article numbers are not unique across categories - for example, you might have an article numbered 56 in category 3, and a similar article number in category 8 - but the combination of article and category number is unique across the site.

A single PHP script takes care of displaying the articles on the site. This script requires the category number and the article number; it then uses this information to connect to the database, retrieve the article identified by those two parameters, and display it appropriately.

Our understanding of the customer's requirements boiled down to the following tasks:

1. Create a PHP script to accept comments from the user, and store these comments in a table.

2. Create a PHP script to display comments for a specific article. An additional requirement here was that comments were to be displayed in a "threaded" fashion, as on USENET bulletin boards.

3. Add appropriate links to read and post comments to the existing user interface.

If you're looking at this from the point of view of your own Web site, the above tasks encompass about 90% of the functionality in any comments system - and they're not even very difficult to accomplish.

This article copyright Melonfire 2001. All rights reserved.

 
 
>>> More Site Administration Articles          >>> More By Vikram Vaswani, (c) Melonfire
 

blog comments powered by Disqus
escort Bursa Bursa escort Antalya eskort
   

SITE ADMINISTRATION ARTICLES

- Coding: Not Just for Developers
- To Support or Not Support IE?
- Administration: Networking OSX and Win 7
- DotNetNuke Gets Social
- Integrating MailChimp with Joomla: Creating ...
- Integrating MailChimp with Joomla: List Mana...
- Integrating MailChimp with Joomla: Building ...
- Integrating MailChimp with Joomla
- More Top WordPress Plugins for Social Media
- Optimizing Security: SSH Public Key Authenti...
- Patches and Rejects in Software Configuratio...
- Configuring a CVS Server
- Managing Code and Teams for Cross-Platform S...
- Software Configuration Management
- Back Up a Joomla Site with Akeeba Backup

Developer Shed Affiliates

 


Dev Shed Tutorial Topics: