Gossamer Forum
Home : Products : Gossamer Links : Discussions :

add.cgi problem

Quote Reply
add.cgi problem
I can't get my add.cgi to work after a new installation.

http://www.categories.ca/....cgi?ID=8759&d=1 for example.

It just returns an internal server error.
>>Premature end of script headers:
/home/categori/public_html/cgi-bin/add.cgi

The other cgi files seem to work (user.cgi etc). Path to perl is correct, file has unix line breaks. I am running Perl 5.6.1.

The permissions seem correct also.

Any ideas?

Crazy

Quote:
#!/usr/local/bin/perl
# ==================================================================
# Links SQL - enhanced directory management system
#
# Website : http://gossamer-threads.com/
# Support : http://gossamer-threads.com/scripts/support/
# CVS Info : 087,071,084,088,082
# Revision : $Id: add.cgi,v 1.48 2001/12/30 19:33:05 alex Exp $
#
# Copyright (c) 2001 Gossamer Threads Inc. All Rights Reserved.
# Redistribution in part or in whole strictly prohibited. Please
# see LICENSE file for full details.
# ==================================================================

use strict;
use lib '/home/categori/public_html/cgi-bin/admin';
use Links qw/$CFG/;
use Links::User::Add;

local $SIG{__DIE__} = \&Links::fatal;

Links::init('/home/categori/public_html/cgi-bin/admin');
Links::init_user();

if (GT::Plugins->dispatch ($CFG->{admin_root_path} . '/Plugins', 'check_request', \&Links::check_request)) {
GT::Plugins->dispatch ($CFG->{admin_root_path} . '/Plugins', 'handle_add', \&Links::User::Add::handle);
}


http://www.iuni.com/...tware/web/index.html
Links Plugins

Last edited by:

Ian: Mar 26, 2003, 10:12 AM
Quote Reply
Re: [Ian] add.cgi problem In reply to
Seems ok for me
Quote Reply
Re: [Paul] add.cgi problem In reply to
Really? Thanks for looking Paul.

I am even more confused now.... I just ran it from the command line:

Quote:
bash-2.05a$ perl add.cgi
Location: http://www.categories.ca/cgi-bin/user.cgi?url=http%3A%2F%2Fwww.categories.ca%2Fcgi-bin%2Fdd.cgi&from=add
Content-type: text/html

I think it is only failing when you are logged in and within a category... hmmmm

Last edited by:

Ian: Mar 26, 2003, 10:20 AM
Quote Reply
Re: [Ian] add.cgi problem In reply to
When I load the page it redirects me to the login page but in order to do that add.cgi must still be executing properly.
Quote Reply
Re: [Paul] add.cgi problem In reply to
Yeah, you are right, that part seems to work fine.

It is when you are logged in and within a category it is failing... this is how I have been testing it (I did not think to test it logged out).

So yes, the cgi must be working, but for some reason it won't do its job when logged in.... the plot thickens.
Quote Reply
Re: [Ian] add.cgi problem In reply to
Do you have a test account?
Quote Reply
Re: [Paul] add.cgi problem In reply to
Errr. no but you can just make one... Paul or something...Cool

I don't care if you add a site or whatever....

Last edited by:

Ian: Mar 26, 2003, 10:25 AM
Quote Reply
Re: [Ian] add.cgi problem In reply to
On the signup error page I get:

Unknown Tag: 'Pass' ..in the password field.

Then when I signup one of your compiled template is corrupt - maybe a template tag issue:

GT::Template (21105): Unable to run compiled template file

Reason: $@: Missing right curly or square bracket at signup_success.html.compiled line 223,
Quote Reply
Re: [Paul] add.cgi problem In reply to
Thanks Paul... it did not do that for me. At least I have something to look at...

I'll check that out, Cheers!
Quote Reply
Re: [Paul] add.cgi problem In reply to
I have it partly working!

I turned off "compress output" in the compile options, and then she-bang, there it was.

I guess I need to force Links to recompile the templates somehow.Smile

Quote:
A fatal error has occured:

GT::Template (25291): Unable to run compiled template file '/home/categori/public_html/cgi-bin/admin/templates/admin/compiled/email-val.txt.compiled'. Reason: $@: . $!: at /home/categori/public_html/cgi-bin/admin/Links/User/Add.pm line 167.

Please enable debugging in setup for more details.

Any ideas how to force links to re-compile the templates in a dynamic setup?

Last edited by:

Ian: Mar 26, 2003, 10:51 AM
Quote Reply
Re: [Ian] add.cgi problem In reply to
Just delete the compiled template.
Quote Reply
Re: [Paul] add.cgi problem In reply to
Cool, thanks for you help Paul!