Home : Products : Others : MySQLMan :

Products: Others: MySQLMan: Re: [jaymuntz] can't delete after table search/select: Edit Log

Here is the list of edits for this post
Re: [jaymuntz] can't delete after table search/select
Hi,

I use Netspace and I've been getting the same errors (v1.09) when trying to delete a record after a search. Having looked at the scripts I've found the following solution:

Edit /mysqlman/GT/CGI.pm - and replace this:

sub html_escape {
#--------------------------------------------------------------------------------
# Return the string html_escaped.
#
my $toencode = (defined $_[0] and ((ref $_[0] eq 'GT::CGI') or ($_[0] eq 'GT::CGI'))) ? $_[1] : $_[0];
return unless (defined $toencode);
if (ref($toencode) eq 'SCALAR') {
$$toencode =~ s/&/&/g;
$$toencode =~ s/</&lt;/g;
$$toencode =~ s/>/&gt;/g;
$$toencode =~ s/"/&quot;/g;
}
else {
$toencode =~ s/&/&amp;/g;
$toencode =~ s/</&lt;/g;
$toencode =~ s/>/&gt;/g;
$toencode =~ s/"/&quot;/g;
}
return $toencode;
}

... with this ...

sub html_escape {
#--------------------------------------------------------------------------------
# Return the string html_escaped.
#
my $toencode = (defined $_[0] and ((ref $_[0] eq 'GT::CGI') or ($_[0] eq 'GT::CGI'))) ? $_[1] : $_[0];
return unless (defined $toencode);
if (ref($toencode) eq 'SCALAR') {
$$toencode =~ s/&/&amp;/g;
$$toencode =~ s/</&lt;/g;
$$toencode =~ s/>/&gt;/g;
$$toencode =~ s/"/&quot;/g;
$$toencode =~ s/ /%20/g;
}
else {
$toencode =~ s/&/&amp;/g;
$toencode =~ s/</&lt;/g;
$toencode =~ s/>/&gt;/g;
$toencode =~ s/"/&quot;/g;
$toencode =~ s/ /%20/g;
}
return $toencode;
}

This makes the delete URL encode properly for the browser.

My only question is - would this change effect any of the other functions of MySQLMan?

All the best
Shaun

Last edited by:

qango: Jan 25, 2002, 3:45 AM

Edit Log: