Gossamer Forum
Home : Products : Gossamer Links : Discussions :

internal Server Errors for all gossamer scripts

(Page 2 of 2)
> >
Quote Reply
Re: [Andy] internal Server Errors for all gossamer scripts In reply to
Now I'm really confused. If it's not required, and so it's not the reason the add.cgi is causing the Internal Server Error, and I don't think the add.cgi itself is corrupt, then where do I go from here?

I'll check with the host and see if they shed any light on it. If you can think of anything else let me know

Lost,

Ron
Quote Reply
Re: [aimcmc] internal Server Errors for all gossamer scripts In reply to
As I said - if you are using my fixed modules (for the latest version of Perl), it will possibly be in there. In /admin/Links/User/Add.pm (and Modify.pm), look for something like:

Code:
use Unicode::MapUTF8 qw(to_utf8 from_utf8 utf8_supported_charset);
map {
$input->{$_} =~ s/([\200-\377]+)/from_utf8({ -string => $1, -charset => 'ISO-8859-1'})/eg;
} keys %$input;

Comment it out if you don't need it. As I said - these are modules that I fixed up for my own site (to get it working on the later version of Perl), so there are some bits that were in there that we not standard as part of the original install)

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] internal Server Errors for all gossamer scripts In reply to
Andy,

Thank you. That did it. I commented out, use Unicode::MapUTF8... in Add.pm. Fixed issue, no longer Internal Server Error at add.cgi.

The, use Unicode::MapUTF8 was not in Modify.pm, so I didn't need to comment it out.

I very much appreciate your help on this.

Ron
Quote Reply
Re: [aimcmc] internal Server Errors for all gossamer scripts In reply to
Cool. Make sure you also comment out:

Code:
map {
$input->{$_} =~ s/([\200-\377]+)/from_utf8({ -string => $1, -charset => 'ISO-8859-1'})/eg;
} keys %$input;

Otherwise, it will try and call the function (which won't exist if you commented out the line before :))

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] internal Server Errors for all gossamer scripts In reply to
As you originally offered, I have commented out both lines, so, yes, that line is too commented out.

Sorry for my ignorance, but what do those lines do, and by removing them, what changes, other than fixing my problem? As long as it works, I'm happy, but I would be interested in knowing the purpose of those lines.

Andy, I thank you, and appreciate your expertise. Things are rough here re the covid, we're lucky to keep our heads above water at the moment, but if I can eventually get things back on track, I'll find a way to pay you back. Thank you.

Ron
Quote Reply
Re: [aimcmc] internal Server Errors for all gossamer scripts In reply to
Hi,

That code just converts UTF-8 content being passed in (via AJAX), going back into ISO-8859-1. Otherwise, you would get issues with stuff like é being garbled. This is only really needed if you are using non-utf8 charsets for your DB/website (some old sites I work on still are set to windows-1252, and this causes issues if you don't do that)

Quote:
Andy, I thank you, and appreciate your expertise. Things are rough here re the covid, we're lucky to keep our heads above water at the moment, but if I can eventually get things back on track, I'll find a way to pay you back. Thank you.

No problem :) All the best

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
> >