I installed Download Mod, I want change title look like to ...
Top : english : english
change to Top: non-english : non-english
how to edit the detail.cgi ?
# Required Librariers
# --------------------------------------------------------
eval {
($0 =~ m,(.*)/[^/]+,) && unshift (@INC, "$1"); # Get the script location: UNIX /
($0 =~ m,(.*)\\[^\\]+,) && unshift (@INC, "$1"); # Get the script location: Windows \
require "admin/links.cfg"; # Change this to full path to links.cfg if you have problems.
require "$db_lib_path/db_utils.pl";
require "$db_lib_path/links.def";
$build_use_templates ?
require "$db_lib_path/site_html_templates.pl" :
require "$db_lib_path/site_html.pl";
};
if ($@) {
print "Content-type: text/plain\n\n";
print "Error including libraries: $@\n[/url]";
print "Make sure they exist, permissions are set properly, and paths are set correctly.";
exit;
}
# ========================================================
eval { &main; }; # Trap any fatal errors so the program hopefully
if ($@) { &cgierr("fatal error: $@"); } # never produces that nasty 500 server error page.
exit; # There are only two exit calls in the script, here and in in &cgierr.
sub main {
# --------------------------------------------------------
%in = &parse_form();
my (%rec) = &get_record ($in{'ID'});
unless ($in{'ID'}) {
&html_print_headers;
print &site_html_detailed_error ("Kein Link angegeben."); #future versions will load a form instead of an error
}
elsif ($rec{$db_key} eq $in{'ID'}) {
$title_unlinked = &build_unlinked_title ("$rec{'Kategorie'}/$rec{'Titel'}");
$title_linked = &build_linked_title ("$rec{'Kategorie'}/$rec{'Titel'}");
$thiscat = $rec{'Kategorie'};
&html_print_headers;
print &site_html_detailed (%rec);
}
else {
&html_print_headers;
print &site_html_detailed_error ("Link $in{'ID'} nicht gefunden.");
}
}
###
# Can't require nph-build -- have to copy this stuff :-)
###
sub build_linked_title {
# --------------------------------------------------------
# Returns a string of the current category broken up
# by section, with each part linked to the respective section.
my $input = shift;
my (@dirs, $dir, $output, $path, $last);
@dirs = split (/\//, $input);
$last = &build_clean(pop @dirs);
$output = qq| <A HREF="$build_root_url/">¶º</A> :|;
foreach $dir (@dirs) {
$path .= "/$dir";
$dir = &build_clean ($dir);
$output .= qq| <A HREF="$build_root_url$path/">$dir</A> :|;
}
$output .= " $last";
return $output;
}
sub build_unlinked_title {
# --------------------------------------------------------
# Returns a string of the current category broken up by section.
# Useful for printing in the title.
my $input = shift;
my (@dirs, $dir, $output);
@dirs = split (/\//, $input);
$output = qq|$build_site_title : |;
foreach $dir (@dirs) {
$dir = &build_clean ($dir);
$output .= " $dir :";
}
chop ($output);
return $output;
}
###
# End of stuff we copied from nph-build.
###
sub error {
# ------------------------------------------
#
print "Content-type: text/html\n\n";
print "Error: $_[0]\n";
exit;
}
Top : english : english
change to Top: non-english : non-english
how to edit the detail.cgi ?
# Required Librariers
# --------------------------------------------------------
eval {
($0 =~ m,(.*)/[^/]+,) && unshift (@INC, "$1"); # Get the script location: UNIX /
($0 =~ m,(.*)\\[^\\]+,) && unshift (@INC, "$1"); # Get the script location: Windows \
require "admin/links.cfg"; # Change this to full path to links.cfg if you have problems.
require "$db_lib_path/db_utils.pl";
require "$db_lib_path/links.def";
$build_use_templates ?
require "$db_lib_path/site_html_templates.pl" :
require "$db_lib_path/site_html.pl";
};
if ($@) {
print "Content-type: text/plain\n\n";
print "Error including libraries: $@\n[/url]";
print "Make sure they exist, permissions are set properly, and paths are set correctly.";
exit;
}
# ========================================================
eval { &main; }; # Trap any fatal errors so the program hopefully
if ($@) { &cgierr("fatal error: $@"); } # never produces that nasty 500 server error page.
exit; # There are only two exit calls in the script, here and in in &cgierr.
sub main {
# --------------------------------------------------------
%in = &parse_form();
my (%rec) = &get_record ($in{'ID'});
unless ($in{'ID'}) {
&html_print_headers;
print &site_html_detailed_error ("Kein Link angegeben."); #future versions will load a form instead of an error
}
elsif ($rec{$db_key} eq $in{'ID'}) {
$title_unlinked = &build_unlinked_title ("$rec{'Kategorie'}/$rec{'Titel'}");
$title_linked = &build_linked_title ("$rec{'Kategorie'}/$rec{'Titel'}");
$thiscat = $rec{'Kategorie'};
&html_print_headers;
print &site_html_detailed (%rec);
}
else {
&html_print_headers;
print &site_html_detailed_error ("Link $in{'ID'} nicht gefunden.");
}
}
###
# Can't require nph-build -- have to copy this stuff :-)
###
sub build_linked_title {
# --------------------------------------------------------
# Returns a string of the current category broken up
# by section, with each part linked to the respective section.
my $input = shift;
my (@dirs, $dir, $output, $path, $last);
@dirs = split (/\//, $input);
$last = &build_clean(pop @dirs);
$output = qq| <A HREF="$build_root_url/">¶º</A> :|;
foreach $dir (@dirs) {
$path .= "/$dir";
$dir = &build_clean ($dir);
$output .= qq| <A HREF="$build_root_url$path/">$dir</A> :|;
}
$output .= " $last";
return $output;
}
sub build_unlinked_title {
# --------------------------------------------------------
# Returns a string of the current category broken up by section.
# Useful for printing in the title.
my $input = shift;
my (@dirs, $dir, $output);
@dirs = split (/\//, $input);
$output = qq|$build_site_title : |;
foreach $dir (@dirs) {
$dir = &build_clean ($dir);
$output .= " $dir :";
}
chop ($output);
return $output;
}
###
# End of stuff we copied from nph-build.
###
sub error {
# ------------------------------------------
#
print "Content-type: text/html\n\n";
print "Error: $_[0]\n";
exit;
}