CNCat 1.2

Installation

The downloaded archive must be unpacked to the directory where you want to run CNCat.

If you have downloaded ZIP archive:

Unzip it with pkunzip supporting long file names (pkzip25 or WinZIP). Additional information about ZIP archivers is available at http://www.pkware.com/.

pkzip25 -extract -dir cncat10.zip

The archive doesn't contain files config.php, _top.php, and _bottom.php, and the previous configuration will not be lost.

After unpacking and copying files to the server, you'll be able to run installation script "install.php", for example http://www.server.com/cncat/install.php, which will help you to create a database and configuration files. If you update CNCat 1.1 or 1.2, all links stored in database will remain untouched.

The installation script will try to create files config.php, _top.php, and _bottom.php, by itself. If it fails, you will be shown sample files and will create these files manually.

When installation is over, you will need to delete the installation script "install.php". Moreover, we strongly recommend to set up the rights disallowing the web-server writing to this file.

Configuration File Description

The configuration file consists of three parts

  1. CNCat settings
  2. CNCat design
  3. Services

In the first part, the CNCat settings are stored.

$db["host"] MySql host
$db["user"] MySql connection login
$db["password"] MySql connection password
$db["name"] Database name
$db["alogin"] Administrator's login for access to administrative interface at http://www.server.com/cncat/admin/
$db["apassword"] MD5 of administrator's password
$cat["mailifnewlink"] Yes – send new link notifications via e-mail No – do not send
$cat["mailifnewlinkto"] E-mail address where notifications will be sent
$cat["mailifnewlinksubject"] Message subject.
$cat["duptestcount"] Number of links automatically checked for reduplications in "New" section of the administrative interface. (value 1 is recommended if the server is slow).
$cat["shownew"] 1 - display "New Links" sections on main page 0 – do not display
$cat["shownewcount"] Number of links to be displayed in "New Links" section
$cat["linksatmain"] 1 – display links on main page 0 – do not (only category is displayed)
$cat["rows"] Number of columns to display directory sections
$CATNAME Name of directory
$LANGFILE Language file. Files for Russian and English are shipped with the software. Additional language files may be downloaded from http://www.cn-software.com/

The second part contains CNCat design settings.

Name Template description Replaceble lines
Link list
linkstopPart of the document before the link listNo
linksmiddlePart of the document between the best and regular links
  • %NUM – sequence number of the first link on the main page.
linksbottomPart of the document after link listNo
linksbitOne link
  • %ID – site identifier
  • %TITLE – site name
  • %DESC – link description
  • %URL – site address
  • %ADMINIFACE – administrative section (available for administrator only)
  • %GIN – number of jumps from site to directory
  • %GOUT – number of jumps from directory to site
  • %MODERVOTE – moderator's grade
  • %BOROKENTEXT – text "Broken Link"
bestlinksbitOne best link
  • %ID – site identifier
  • %DESC – link description
  • %TITLE – site name
  • %URL – site address
  • %ADMINIFACE – administrative section (available for administrator only)
  • %GIN – number of jumps from site to directory
  • %GOUT – number of jumps from directory to site
  • %MODERVOTE – moderator's grade
  • %BOROKENTEXT – text "Broken Link"
Section "New Links"
newlinkstopUpper part of "New Links" section
  • %NEWLINKSTEXT - text "New Links"
newlinkstbottomBottom part of "New Links" sectionNo
newlinkstbitNew link
  • %ID – site identifier
  • %TITLE – site name
  • %URL – site address
  • %DESC – link description
  • %DESC75 – short description
  • %ADMINIFACE – administrative section (available for administrator only)
  • %GIN – number of jumps from site to directory
  • %GOUT – number of jumps from directory to site
  • %MODERVOTE – moderator's grade
List of categories
partstopUpper part of categories sectionNo
partsdelimtopStart of new line of categories sectionNo
partsdelimbottomEnd of new line of categories sectionNo
partsbottomBottom part of categories sectionNo
partsbitName of the category
  • %CID – category identifier
  • %CTITLE – category name
  • %CCOUNT – number of links in the category
Search
searchformSearch form
  • %QUERYTEXT – search request
  • %SEARCHTEXT – text «Perform search»
searchtopPart of document before list of links
  • %STARTNUM – sequence number of the first link on page.
searchbottomPart of the document after link listNo
Miscellaneuos
catnameCategory name section
  • %MAINTEXT – Name of directory
  • %OTHERTEXT – Section name
sortbySorting section
  • %SORTBYTEXT – Text «Sort by»
  • %SORTBYPOP – popularity
  • %SORTBYTITLE - name
  • %SORTBYMODER – moderator's grade
brokenscriptBroken links information script
  • %YESTEXT – Text "Yes"
  • %NOTEXT – Text "No"
  • %BROKENSURETEXT – Sending notification confirmation text

The third part - services.

You may change $COPY variable or even delete it. But, license agreement requires logo and name of software be displayed on each page of the directory.

What's New in Version 1.2

1. Added use of $HTTP_POST_VARS when new link had been added.

2. Added option of editing links on results page.

3. Optional display of link list on the main page.

4. Appearance may be set up how you want it. (Do not change this file, if you want to easily upgrate to newer versions of CNCat. To change appearance set up files: _top.php, _bottom.php and config.php)

5. Added installation script, which will help you to install CNCat or upgrade it from any version.

What's New in Version 1.1

1. Directory sections editing and synchronisation option added.

2. Broken links notification added.

3. New link notification added. The notification is e-mailed to site administrator. To enable it, the following changes to the configuration file should be performed:

$cat["mailifnewlink"]="yes";
$cat["mailifnewlinkto"]="support@cn-software.com";

E-Mail, where notification will be sent.

$cat["mailifnewlinksubject"]="New Link";

E-Mail subject.

This option is very useful, if links are not added to your directory very often - there is no need to visit administrator's page and look for new links.

4. More flexible design added. The following style table has been added: (see _top.php)

<STYLE>
<!--
.tbl0 {background-color:#D0D0D0;color:white;}
.tbl1 {background-color:#F0F0F0;}
.tbl2 {background-color:#D0D0D0;}
-->
</STYLE>

5. New links may be displayed on the main page:

$cat["newlinksbordercolor"]="#896819";
$cat["newlinksbgcolor"]="#FFEEB3";

Table and border colors for new links.

$cat["shownew"]=1;
$cat["shownewcount"]=4;

Number of new links to display.

6. Double link automatic checking added. First N links in "New" section will be automatically checked for doubling.

$cat["duptestcount"]=1;

Sets number of links to check (N). Every check calls for a separate SQL query. Set to 10 if you have a powerful server.

License

Installing CNCat you agree to the following terms:

You may use CNCat at your site regardless of its type - commercial or non-commercial. CN-Software copyrights must be present in system code, CN-Software graphical or text link must be present on EVERY page, created by CNCat. The link must be:

You are allowed to modify CNCat code, leaving our copyrights inside the code, as well as on pages created by the script. You are NOT ALLOWED to distribute modified CNCat code.

You are not allowed to:

If you want to remove CNCat logos or links, you must contact CN-Software Support Team for details and terms via e-mail support@novsu.ac.ru

Script CNCat is distributed "AS IS", you are using it at your own risk and the script authors do not bear responsibility for any damage (mental, financial, circumstantial or any other) caused by script performance.