Hi! i'm making change in my sites, and i want to call in the home page the last 4 records from DB with SSI.
I make this only change in sub html_view_succes:
from this code:
# --------------------------------------------------------
my (@hits) = @_;
my ($numhits) = ($#hits+1) / ($#db_cols+1);
my ($maxhits); $in{'mh'} ? ($maxhits = $in{'mh'}) : ($maxhits = $db_max_hits);
$in{'nh'} ? ($nh = $in{'nh'}) : ($nh = 1);
$page_title = "Lista";
# the code continue for printing each record in two columns
to this:
# --------------------------------------------------------
my (@hits) = @_;
my ($numhits) = ($#hits+1) / ($#db_cols+1);
my ($maxhits); $in{'mh'} ? ($maxhits = $in{'mh'}) : ($maxhits = $db_max_hits);
$in{'nh'} ? ($nh = $in{'nh'}) : ($nh = 1);
$page_title = "Lista";
if ($in{'view_ssi'}) {
for (0 .. $numhits - 1) {
print "<P>";
&html_record (&array_to_hash($_, @hits));
}
} else {
# the code continue for printing each record in two columns
I only try to print without the &html_page_top and &html_page_botton. Trying this mods make 500 Server Error only when use &view_ssi=1 in the querystring.
what i doing wrong? i repeat, i want to show the records without the TOP and BOTTON layouts.
Thanks.
------------------
Gustavo.
www.roldigital.com.ar/conjuros/
I make this only change in sub html_view_succes:
from this code:
Code:
sub html_view_success { # --------------------------------------------------------
my (@hits) = @_;
my ($numhits) = ($#hits+1) / ($#db_cols+1);
my ($maxhits); $in{'mh'} ? ($maxhits = $in{'mh'}) : ($maxhits = $db_max_hits);
$in{'nh'} ? ($nh = $in{'nh'}) : ($nh = 1);
$page_title = "Lista";
# the code continue for printing each record in two columns
to this:
Code:
sub html_view_success { # --------------------------------------------------------
my (@hits) = @_;
my ($numhits) = ($#hits+1) / ($#db_cols+1);
my ($maxhits); $in{'mh'} ? ($maxhits = $in{'mh'}) : ($maxhits = $db_max_hits);
$in{'nh'} ? ($nh = $in{'nh'}) : ($nh = 1);
$page_title = "Lista";
if ($in{'view_ssi'}) {
for (0 .. $numhits - 1) {
print "<P>";
&html_record (&array_to_hash($_, @hits));
}
} else {
# the code continue for printing each record in two columns
I only try to print without the &html_page_top and &html_page_botton. Trying this mods make 500 Server Error only when use &view_ssi=1 in the querystring.
what i doing wrong? i repeat, i want to show the records without the TOP and BOTTON layouts.
Thanks.
------------------
Gustavo.
www.roldigital.com.ar/conjuros/