Gossamer Forum
Home : Products : Gossamer Links : Discussions :

browser.cgi is using wrong template set

Quote Reply
browser.cgi is using wrong template set
Hi there,

I just installed the 2.04 upgrade (fresh install) and when I login through the site (not the admin section) as admin then go to the editor, the script is using the templates found in templates/admin instead of templates/default, and all of my links are trying accessing path_to_cgi/admin.cgi(notfound) instead of path_to_cgi/browser.cgi.

Is this because I'm user -> admin, or is there something else going on here that is telling 2.04 to use the templates/admin browser files instead of the templates/default browser files?

peace.

Quote Reply
Re: browser.cgi is using wrong template set In reply to
Odd... I haven't hit this problem.

I'll check more carefully tonight, but I've used the admin edit, as well as the user edit features on the two sites I've set up with 2.04 and not had a problem.

The only "problem" is the user edit loses the header, so it still doesn't display the site title and nav bars. This probably could be fixed by just moving the frame set over, and changing the top file to the header file.

PUGDOGŪ Enterprises, Inc.
FAQ:http://LinkSQL.com/FAQ
Forum:http://LinkSQL.com/forum
Quote Reply
Re: browser.cgi is using wrong template set In reply to
Hmm, it's still happening.

I've reuploaded the .dat install file and the install.cgi file. I did the upgrade install and chose backup.
it did it's thing and the dates are reset to what they were. Still having the problem.

I'm using the web interface for the install. Not the telnet install.

I went back to Gossamer and downloaded another version and redid the whole thing choosing overwrite this time. Still having the problem.

So, Where do I look to figure out how the browser.cgi script as found above the admin directory chooses it's template set. It's looking into the templates/admin directory for the template set, not the templates/default directory.

peace.

Quote Reply
More Info In reply to
Well this is odd.

I find that when I login through the site and access the editors function as a user with Administrator status then I run into this problem, But when I login as a user with a Registered Status who is setup as an Editor then I don't run into this problem. This would probably be fine, accept that someone with the status of Administrator can't do anything, because the script is trying to access url-to-browser/admin.cgi instead of url-to-browser/admin/admin.cgi.

Please help.

peace.

Quote Reply
Re: More Info In reply to
Ok,

THat is what I thought might have been happening.

I don't know these routines well enough to offer a fix at this point.

It could be as simple as adjusting the check for "admin" status to also look for whether the log-in is from the admin or not. It might be more complicated over all, but it might also just be a little bug that can be easily fixed.



PUGDOGŪ Enterprises, Inc.
FAQ:http://LinkSQL.com/FAQ
Forum:http://LinkSQL.com/forum
Quote Reply
Re: More Info In reply to
Hi Kyle,

It's in Links/Browser.pm:

if ($self->{ctrl}->{admin}) {
Links::admin_page ($tpl, $vars, $opts);
}
else {
Links::user_page ($tpl, $vars, $opts);
}

If you are an admin, then you use the admin pages. This is because the admin side uses the exact same code. I'll look into improving this so the template pick comes from where you enter, not your status.

Cheers,

Alex

--
Gossamer Threads Inc.