User Tools

Site Tools


developers:introduction

Developers

The main part of the script is the file /comments/includes/commentics.php. This file loads the language definitions, functions and classes before then displaying the output using the template files. In doing this it is also responsible for the following:

  • Connecting the database
  • Loading the settings
  • Error reporting level
  • Detecting the administrator
  • Maintenance Mode
  • Validating the page ID
  • Setting the time zone
  • Unbanning users
  • Adding viewers
  • Running the task system

Other Parts

In addition to commentics.php, other independent files include /comments/rss.php, /comments/subscribers.php, /comments/flag.php and /comments/vote.php.

Database

To connect to the database, load the file /comments/includes/db/connect.php. The database contains the following tables:

  • access
  • admins
  • attempts
  • bans
  • comments
  • logins
  • pages
  • questions
  • reporters
  • settings
  • subscribers
  • version
  • viewers
  • voters

As of Commentics v2.0, to retrieve a database setting you can use the syntax $cmtx_settings→name_of_setting. If inside a function then you will need to make sure that the $cmtx_settings variable is globalized, like so:

global $cmtx_settings;

External Scripts

developers/introduction.txt · Last modified: 2013/03/03 21:06 by steven