Gossamer Forum
Home : Products : Links 2.0 : Customization :

..Detailed/1.html into ...Detailed/Site_Name.html

Quote Reply
..Detailed/1.html into ...Detailed/Site_Name.html
Hello Smile

I`m very close to finishing my site based on 'Links 2.0' ...that actualy handles Games Downloads.

I need to change nph-build.cgi - i think...so that when i build the static pages i will have something like this : http://www..............Detailed/Site_Name.html ..... or in my case http://www..............Detailed/Game_Name.html ...i`m still inspecting nph-build.cgi ..but if you can tell me ..it will save me a lot of time ..

Thanks for your help & have a nice day !

Kind Regrads,
Durigu Rares.
Quote Reply
Re: [at0m] ..Detailed/1.html into ...Detailed/Site_Name.html In reply to
Try editing nph-build.cgi's build_detailed_view routine. I've made a simple hack here, but I'm not definate it will work.

Code:
sub build_detailed_view {
# --------------------------------------------------------
# This routine build a single page for every link.
#
my (@values, $id, %rec, $count);
if ($build_detail_path =~ m,^$build_root_path/(.*)$,) {
&build_dir ($1);
}
print "\t";
open (DB, "<$db_file_name") or &cgierr("unable to open database: $db_file_name. Reason: $!");
LINE: while (<DB>) {
/^#/ and next LINE; # Skip comment Lines.
/^\s*$/ and next LINE; # Skip blank lines.
chomp;
@values = &split_decode ($_);
$id = $values[$db_key_pos];
%rec = &array_to_hash (0, @values);
$title_linked = &build_linked_title ("$rec{'Category'}/$rec{'Title'}");
my $_file = $rec{'Title'} . "/" . $build_extension/
open (DETAIL, ">$build_detail_path/$_file") or &cgierr ("Unable to build detail page: $build_detail_path/$_file. Reason: $!");
print DETAIL &site_html_detailed (%rec);
close DETAIL;
$use_html ?
print qq~<a href="$build_detail_url/$_file" target="_blank">$id</a> ~ :
print qq~$id ~;
(++$count % 10) or print "\n\t";
}
close DB;
print "\n";
}

Cheers

Andy (mod)
andy@ultranerds.co.uk


IMPORTANT: I've now moved to ultranerds.co.uk, and the .com will no longer work!
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates
Quote Reply
Re: [Andy] ..Detailed/1.html into ...Detailed/Site_Name.html In reply to
This didn`t seem to work...Unsure ...i really appreciate you trying to help !
Quote Reply
..Detailed/1.html into ...Detailed/Site_Name.html In reply to
Hello!...
Can someone else please try to help on this small modification ?...
Thanks !
Quote Reply
Re: [at0m] ..Detailed/1.html into ...Detailed/Site_Name.html In reply to
Don't know if this will make a difference, but the following line;

my $_file = $rec{'Title'} . "/" . $build_extension/

...should have been...

my $_file = $rec{'Title'} . $build_extension;

Cheers

Andy (mod)
andy@ultranerds.co.uk


IMPORTANT: I've now moved to ultranerds.co.uk, and the .com will no longer work!
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package (plugins total "value" $3,325 & rising, for just $350)| GLinks ULTRA Package PRO (plugins total "value" $5,625 & rising, for just $500)
Support Forum | Links SQL Plugins | DMOZ Dumps | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Compare our different Plugin packages *new* Free CSS Templates
Quote Reply
Re: [Andy] ..Detailed/1.html into ...Detailed/Site_Name.html In reply to
Great !...you know what that means ;) ( that it worked ;) )...thanks man!...Hope you have a nice day for the nice thing you did...