Gossamer Forum
Home : Products : Links 2.0 : Installation -- Unix :

Links.def has too many errors

Quote Reply
Links.def has too many errors
First, I've done a search on the boards and was unable to find this particular error.

Following other posts here, I've fixed the location of the perl directory. I believe I have the correct full paths listed, set permissions (sort of, I can only set one type of permission for the entire site), and uncommented the cgierror line.

When running admin.cgi, I get the following error:


CGI ERROR
==========================================
Error Message : fatal error: /usr/local/apache/www/digitalartlinks.com/cgi-bin/links/admin/links.def has too many errors.

Script Location : /usr/local/apache/www/digitalartlinks.com/cgi-bin/links/admin/admin.cgi
Perl Version : 5.00503

Form Variables
-------------------------------------------

Environment Variables
-------------------------------------------
DOCUMENT_ROOT : /www/digitalartlinks.com/htdocs
GATEWAY_INTERFACE : CGI/1.1
HTTP_ACCEPT : */*
HTTP_ACCEPT_ENCODING: gzip, deflate
HTTP_ACCEPT_LANGUAGE: en-us
HTTP_CONNECTION : Keep-Alive
HTTP_HOST : www.digitalartlinks.com
HTTP_USER_AGENT : Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)
PATH : /sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin
QUERY_STRING :
REMOTE_ADDR : 65.189.211.105
REMOTE_PORT : 1190
REQUEST_METHOD : GET
REQUEST_URI : /cgi-bin/links/admin/admin.cgi
SCRIPT_FILENAME : /usr/local/apache/www/digitalartlinks.com/cgi-bin/links/admin/admin.cgi
SCRIPT_NAME : /cgi-bin/links/admin/admin.cgi
SERVER_ADDR : 64.159.74.225
SERVER_ADMIN : you@your.address
SERVER_NAME : www.digitalartlinks.com
SERVER_PORT : 80
SERVER_PROTOCOL : HTTP/1.1
SERVER_SIGNATURE : Apache/1.3.26 Server at www.digitalartlinks.com Port 80



SERVER_SOFTWARE : Apache/1.3.26 (Unix)

~~~~~

Here is my links.def:

# -------------
# Links
# -------------
# Links Manager
#
# File: links.def
# Description: Contains the database definition for links.
# Author: Alex Krohn
# Email: alex@gossamer-threads.com
# Web: http://www.gossamer-threads.com/
# Version: 2.01
#
# (c) 1998 Gossamer Threads Inc.
#
# This script is not freeware! Please read the README for full details
# on registration and terms of use.
# =====================================================================

# Database Definition: LINKS
# --------------------------------------------------------
# Definition of your database file.
%db_def = (
ID => [0, 'numer', 5, 8, 1, '', ''],
Title => [1, 'alpha', 40, 75, 1, '', ''],
URL => [2, 'alpha', 40, 75, 1, 'http://', '^http|news|mailto|ftp'],
Date => [3, 'date', 15, 15, 1, \&get_date, ''],
Category => [4, 'alpha', 0, 150, 1, '', ''],
Description => [5, 'alpha', '40x3', 500, 0, '', ''],
'Contact Name' => [6, 'alpha', 40, 75, 1, '', ''],
'Contact Email' => [7, 'alpha', 40, 75, 1, '', '.+@.+\..+'],
Hits => [8, 'numer', 10, 10, 1, '0', '\d+'],
isNew => [9, 'alpha', 0, 5, 0, 'No', ''],
isPopular => [10, 'alpha', 0, 5, 0, 'No', ''],
Rating => [11, 'numer', 10, 10, 1, 0, '^[\d\.]+$'],
Votes => [12, 'numer', 10, 10, 1, 0, '^\d+$'],
ReceiveMail => [13, 'alpha', 10, 10, 1, 'Yes', 'No|Yes']
);

# Database file to use -- defined in links.cfg.
$db_file_name = $db_links_name;
# Counter file to use -- defined in links.cfg.
$db_id_file_name = $db_links_id_file_name;
# The column name for the database key.
$db_key = 'ID';
# Database delimeter.
$db_delim = '|';
# Title used in admin output.
$html_title = 'Links Database';
$html_object = 'Link';

# Field Number of some important fields. The number is from %db_def above
# where the first field equals 0.
$db_category = 4; $db_modified = 3; $db_url = 2;
$db_hits = 8; $db_isnew = 9; $db_ispop = 10;
$db_contact_name = 6; $db_contact_email = 7; $db_title = 1;
$db_votes = 12; $db_rating = 11; $db_mail = 13;

# Field number to sort links by:
$db_sort_links = 1;

# Field names you want to allow visitors to search on:
@search_fields = (1,2,5);

# System defaults. When adding new links or modifying links, these fields
# can not be overwritten by a user.
%add_system_fields = (
isNew => 'No',
isPopular => 'No',
Hits => '0',
Rating => 0,
Votes => 0,
ReceiveMail => 'Yes'
);

# Hash of column names to possible options. If you want to use a select form
# field, you can use &build_select_field in your HTML page. This routine will
# make a <SELECT> input tag using the following values:
%db_select_fields = (
isNew => 'Yes,No',
isPopular => 'Yes,No',
ReceiveMail => 'Yes,No'
);

# Hash of column names to radio values. If you use &build_radio_field, it will
# make a <INPUT TYPE="RADIO"> tag for you using the options specified in the hash.
%db_radio_fields = ( );

# Maximum number of hits returned in a search. Can be overridden in the search
# options.
$db_max_hits = 10;

# Use the built in key tracker.
$db_key_track = 1;

# ===========================================================================
# Build up some variables from your definitions. Internal use only.
@db_cols = ();
foreach (sort { $db_def{$a}[0] <=> $db_def{$b}[0] } keys %db_def) {
push (@db_cols, $_);
$db_sort{$_} = $db_def{$_}[1];
$db_form_len{$_} = $db_def{$_}[2];
$db_lengths{$_} = $db_def{$_}[3];
$db_not_null{$_} = $db_def{$_}[4];
$db_defaults{$_} = $db_def{$_}[5];
$db_valid_types{$_} = $db_def{$_}[6];
($_ eq $db_key) and $db_key_pos = $db_def{$_}[0];
}

1;

~~~~~

I know absolutely nothing about perl and just enough Unix to get in trouble. If there is any other information you need, please let me know.

TIA
-darlisa

http://www.fignations.com
Quote Reply
Re: [riggsd] Links.def has too many errors In reply to
What's the deal with all the ">" being replaced with ">"

Philip
------------------
Limecat is not pleased.
Quote Reply
Re: [fuzzy thoughts] Links.def has too many errors In reply to
Seems I recall having that problem when I first did some uploading to a server. Some programs, maybe notepad, or if the file went through an HTML editor, will convert symbols to HTML code (> = >). Suggest uploading that file again, making sure it transfers properly...


Leonard
aka PerlFlunkie
Quote Reply
Re: [PerlFlunkie] Links.def has too many errors In reply to
Thanks to both of you. I uploaded a replacement file and it now works. Off to get the next step working.
-darlisa

http://www.fignations.com
Quote Reply
Re: [PerlFlunkie] Links.def has too many errors In reply to
Is there a way to have the link pages created on my computer so that I can upload them later to my site? To clarify, can I run the Build All from my site, but have the pages created on my personal computer? I have a static IP address if that helps.
-darlisa

http://www.fignations.com
Quote Reply
Re: [riggsd] Links.def has too many errors In reply to
Guess that depends on how "savvy" you are... You can install a version of Perl on your computer, and you would probably need Unix, too, then you could run the script on your home computer. You can patrition your hard drive with a MS area and a Unix area, or better, have removable hard drives that you can switch back and forth. If you got the money, the technology is there...


Leonard
aka PerlFlunkie
Quote Reply
Re: [PerlFlunkie] Links.def has too many errors In reply to
No need for Unix... Modifiy nph-build.cgi so that during a build, it uses Net:FTP to upload files after they are rebuilt.

Philip
------------------
Limecat is not pleased.
Quote Reply
Re: [fuzzy thoughts] Links.def has too many errors In reply to
In Reply To:
No need for Unix... Modifiy nph-build.cgi so that during a build, it uses Net:FTP to upload files after they are rebuilt.


How would I do this?

I have all the permissions on all directories and folders set to 777 right now, the server owner has checked and they are all set that way, and the script can't make backups, make directories, or create html files - getting permission denied errors and I've checked all kinds of messages here and tried everything suggested with no luck.

If I can have the pages built on my machine, without have to load perl or anything (which I can't afford anyway) then I can just upload the files after they are built, whether manually or having the program do it.

(hopeful look)
-darlisa

http://www.fignations.com